.case-opening-content.reduced-effects .case-visual-shell.case-tier-surge .case-visual-core {
  animation: none;
}
@font-face {
  font-family: "FuturaPT";
  src: url("/DesignAssets/Font/FuturaPT-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
}

@font-face {
  font-family: "FuturaPT";
  src: url("/DesignAssets/Font/FuturaPT-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
}

@font-face {
  font-family: "FuturaPT";
  src: url("/DesignAssets/Font/FuturaPT-Book.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
}

:root {
  --chibi-pink: #ff9ec8;
  --chibi-purple: #c084fc;
  --chibi-blue: #60a5fa;
  --chibi-bg: #1a0f2e;
  --chibi-card: #2d1b4e;
  --chibi-border: #4a2c6b;
  --chibi-text: #ffffff;
  --chibi-text-muted: #d1d5db;
  --chibi-gold: #fbbf24;
  --chibi-extrapass: #f59e0b;
  --chibi-red: #ef4444;
  --chibi-orange: #f97316;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  font-family: "FuturaPT", "Comic Sans MS", "Comic Sans", "Arial Rounded MT Bold", sans-serif;
  background: linear-gradient(135deg, #1a0f2e 0%, #2d1b4e 50%, #1a0f2e 100%);
  background-attachment: fixed;
  color: var(--chibi-text);
  overflow-x: hidden;
  min-height: 100vh;
}

/* ─── In-game shop redesign ─── */
.ea-shop-root {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 14px calc(24px + var(--ea-safe-bottom-soft));
  background:
    radial-gradient(circle at 18% 0%, rgba(245, 146, 30, 0.12), transparent 28%),
    radial-gradient(circle at 92% 8%, rgba(45, 212, 191, 0.1), transparent 28%),
    linear-gradient(180deg, rgba(19, 13, 38, 0.98), rgba(15, 10, 26, 0.98));
  scrollbar-width: none;
}

.ea-shop-root::-webkit-scrollbar {
  display: none;
}

.ea-shop-root button {
  font-family: "FuturaPT", "Exo 2", sans-serif;
}

.ea-shop-section {
  margin-top: 18px;
}

.ea-shop-section:first-child {
  margin-top: 2px;
}

.ea-shop-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 2px 10px;
}

.ea-shop-section-title h2 {
  margin: 0;
  color: #f0ecff;
  font-family: "FuturaPT", "Exo 2", sans-serif;
  font-size: 18px;
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: 0;
}

.ea-shop-section-title span {
  color: #7a6fa0;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.ea-shop-bundles {
  display: grid;
  gap: 10px;
}

.ea-shop-bundle {
  position: relative;
  min-height: 154px;
  padding: 14px;
  border: 1px solid rgba(251, 191, 36, 0.55);
  border-radius: 20px;
  overflow: hidden;
  background:
    linear-gradient(130deg, rgba(251, 191, 36, 0.2), rgba(124, 92, 191, 0.18) 48%, rgba(45, 31, 82, 0.96)),
    #1a1030;
  box-shadow: 0 10px 34px rgba(0, 0, 0, 0.24);
}

.ea-shop-bundle::after {
  content: "";
  position: absolute;
  inset: -42% -22% auto auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.24), transparent 66%);
  pointer-events: none;
}

.ea-shop-bundle-copy {
  position: relative;
  z-index: 2;
  width: min(62%, 230px);
}

.ea-shop-eyebrow {
  color: #ffd700;
  font-size: 10px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ea-shop-eyebrow.blue {
  color: #bfdbfe;
}

.ea-shop-bundle h3 {
  margin: 7px 0 6px;
  color: #f0ecff;
  font-size: 22px;
  line-height: 0.95;
  font-weight: 900;
  letter-spacing: 0;
}

.ea-shop-bundle p,
.ea-shop-small-copy {
  margin: 0;
  color: #c4b8e8;
  font-size: 12px;
  line-height: 1.35;
}

.ea-shop-reward-line {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.ea-shop-chip {
  border-radius: 999px;
  padding: 4px 7px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #f0ecff;
  font-size: 10px;
  line-height: 1;
  font-weight: 900;
  white-space: nowrap;
}

.ea-shop-bundle-art {
  position: absolute;
  right: -14px;
  bottom: -9px;
  z-index: 1;
  width: 170px;
  height: 136px;
}

.ea-shop-case-art {
  position: absolute;
  right: 0;
  bottom: 4px;
  width: 136px;
  filter: drop-shadow(0 16px 22px rgba(0, 0, 0, 0.45));
}

.ea-shop-card-mini {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 58px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 8px;
  transform: rotate(-8deg);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.45);
}

.ea-shop-cta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.ea-shop-price,
.ea-shop-mini-buy {
  min-height: 34px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #f5921e, #ff4d2e);
  box-shadow: 0 9px 22px rgba(245, 146, 30, 0.28);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.ea-shop-price {
  padding: 0 14px;
}

.ea-shop-root button:disabled {
  cursor: default;
  opacity: 0.56;
}

.ea-shop-ghost-price {
  color: #7a6fa0;
  font-size: 11px;
  font-weight: 700;
}

.ea-shop-pack-grid {
  display: grid;
  gap: 12px;
}

.ea-shop-pack-card {
  --pack-accent: #fbbf24;
  --pack-accent-2: #f5921e;
  --pack-glow: rgba(251, 191, 36, 0.24);
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 118px;
  gap: 10px;
  min-height: 190px;
  padding: 13px;
  border: 1px solid color-mix(in srgb, var(--pack-accent) 54%, rgba(255,255,255,0.16));
  border-radius: 22px;
  overflow: hidden;
  background:
    radial-gradient(circle at 86% 8%, var(--pack-glow), transparent 34%),
    linear-gradient(140deg, rgba(45, 31, 82, 0.96), rgba(26, 16, 48, 0.98));
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255,255,255,0.07);
}

.ea-shop-pack-variant-cosmetic {
  grid-template-columns: 1fr;
  min-height: 372px;
}

.ea-shop-pack-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(115deg, rgba(255,255,255,0.08), transparent 36%, rgba(255,255,255,0.035));
}

.ea-shop-pack-variant-cosmetic {
  --pack-accent: #a78bfa;
  --pack-accent-2: #60a5fa;
  --pack-glow: rgba(167, 139, 250, 0.28);
}

.ea-shop-pack-variant-card {
  --pack-accent: #60a5fa;
  --pack-accent-2: #2dd4bf;
  --pack-glow: rgba(96, 165, 250, 0.3);
  grid-template-columns: minmax(0, 1fr) 128px;
  min-height: 248px;
}

.ea-shop-pack-card-mode-card-cosmetic {
  grid-template-columns: 1fr;
  min-height: 430px;
}

.ea-shop-pack-gift {
  --pack-accent: #4ade80;
  --pack-accent-2: #2dd4bf;
  --pack-glow: rgba(74, 222, 128, 0.28);
}

.ea-shop-pack-copy,
.ea-shop-pack-media,
.ea-shop-pack-footer {
  position: relative;
  z-index: 1;
}

.ea-shop-pack-copy {
  min-width: 0;
  padding-bottom: 52px;
}

.ea-shop-pack-variant-cosmetic .ea-shop-pack-copy {
  padding-bottom: 0;
}

.ea-shop-pack-card-mode-card-cosmetic .ea-shop-pack-copy {
  padding-bottom: 0;
}

.ea-shop-pack-topline {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.ea-shop-pack-badge {
  max-width: 112px;
  padding: 3px 7px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--pack-accent) 20%, rgba(255,255,255,0.06));
  border: 1px solid color-mix(in srgb, var(--pack-accent) 42%, rgba(255,255,255,0.08));
  color: var(--pack-accent);
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: uppercase;
}

.ea-shop-pack-card h3 {
  margin: 7px 0 5px;
  color: #fff;
  font-size: 21px;
  line-height: 0.96;
  font-weight: 900;
  letter-spacing: 0;
}

.ea-shop-pack-card p {
  margin: 0;
  color: #c4b8e8;
  font-size: 11.5px;
  line-height: 1.28;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.ea-shop-pack-card-details {
  display: grid;
  gap: 5px;
  margin-top: 8px;
  padding: 8px;
  border-radius: 14px;
  background: rgba(5, 2, 12, 0.28);
  border: 1px solid color-mix(in srgb, var(--pack-accent) 28%, rgba(255,255,255,0.08));
}

.ea-shop-pack-card-name {
  min-width: 0;
  color: #eef6ff;
  font-size: 11px;
  line-height: 1.08;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ea-shop-pack-card-stats,
.ea-shop-info-card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.ea-shop-pack-card-stats span,
.ea-shop-info-card-stats span {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  min-width: 0;
  padding: 3px 6px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--pack-accent) 20%, rgba(255,255,255,0.06));
  border: 1px solid color-mix(in srgb, var(--pack-accent) 32%, rgba(255,255,255,0.08));
  color: #fff;
  font-size: 10px;
  line-height: 1;
  font-weight: 900;
}

.ea-shop-pack-card-stats span[class^="rarity-"],
.ea-shop-info-card-stats span[class^="rarity-"] {
  background: color-mix(in srgb, var(--pack-accent) 28%, rgba(255,255,255,0.06));
  border-color: color-mix(in srgb, var(--pack-accent) 52%, rgba(255,255,255,0.08));
  color: #fff;
}

.ea-shop-pack-card-stats b,
.ea-shop-info-card-stats b {
  color: #bfdbfe;
  font-size: 9px;
  text-transform: uppercase;
}

.ea-shop-pack-card-description,
.ea-shop-pack-card-mechanics {
  min-width: 0;
  color: #c4b8e8;
  font-size: 10px;
  line-height: 1.24;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.ea-shop-pack-card-mechanics {
  color: #bfdbfe;
  font-style: normal;
}

.ea-shop-pack-fallback-note {
  margin-top: 8px !important;
  padding: 7px 9px;
  border-radius: 12px;
  border: 1px solid rgba(167,139,250,0.28);
  background: rgba(167,139,250,0.12);
  color: #ddd6fe !important;
  -webkit-line-clamp: 3 !important;
}

.ea-shop-pack-rewards {
  position: relative;
  z-index: 1;
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 0;
  padding-bottom: 52px;
  min-width: 0;
}

.ea-shop-pack-resource,
.ea-shop-pack-cosmetic {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 4px 6px;
  border-radius: 999px;
  background: rgba(5, 2, 12, 0.36);
  border: 1px solid rgba(255,255,255,0.1);
  color: #f0ecff;
  font-size: 10px;
  line-height: 1;
  font-weight: 900;
}

.ea-shop-pack-resource.gems { border-color: rgba(167,139,250,0.42); color: #ddd6fe; }
.ea-shop-pack-resource.coins { border-color: rgba(245,146,30,0.42); color: #fed7aa; }
.ea-shop-pack-resource.keys { border-color: rgba(96,165,250,0.42); color: #bfdbfe; }

.ea-shop-pack-resource-icon {
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.ea-shop-pack-resource-icon img {
  width: 16px;
  height: 16px;
  object-fit: contain;
}

.ea-shop-pack-resource.keys .ea-shop-pack-resource-icon {
  border-radius: 50%;
  background: #bfdbfe;
}

.ea-shop-pack-resource.keys .ea-shop-pack-resource-icon img {
  width: 12px;
  height: 12px;
}

.ea-shop-pack-resource b,
.ea-shop-pack-cosmetic b {
  margin-right: 3px;
  color: #fff;
}

.ea-shop-pack-cosmetic {
  max-width: 148px;
}

.ea-shop-pack-cosmetic img,
.ea-shop-pack-cosmetic i {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  border-radius: 6px;
  object-fit: cover;
  display: grid;
  place-items: center;
  background: rgba(167,139,250,0.16);
  color: #ddd6fe;
  font-style: normal;
}

.ea-shop-pack-cosmetic.background img {
  width: 28px;
  border-radius: 5px;
  object-fit: contain;
  background: rgba(255,255,255,0.06);
}

.ea-shop-pack-cosmetic span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ea-shop-pack-media {
  min-width: 0;
  align-self: start;
  display: grid;
  place-items: stretch;
}

.ea-shop-pack-variant-cosmetic .ea-shop-pack-media {
  grid-column: 1 / -1;
  width: 100%;
}

.ea-shop-pack-card-mode-card-cosmetic .ea-shop-pack-media {
  grid-column: 1 / -1;
  width: 100%;
}

.ea-shop-pack-hero-resources,
.ea-shop-pack-hero-cosmetics,
.ea-shop-pack-hero-card {
  width: 100%;
  height: 132px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.11);
  background: rgba(5,2,12,0.32);
  overflow: hidden;
}

.ea-shop-pack-hero-resources {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  padding: 9px;
}

.ea-shop-pack-hero-resources span {
  min-width: 0;
  display: grid;
  place-items: center;
  gap: 3px;
  border-radius: 13px;
  background: color-mix(in srgb, var(--pack-accent) 17%, rgba(255,255,255,0.06));
  border: 1px solid color-mix(in srgb, var(--pack-accent) 32%, rgba(255,255,255,0.08));
  color: #fff;
}

.ea-shop-pack-hero-resources span.keys {
  background: linear-gradient(135deg, rgba(191,219,254,0.28), rgba(96,165,250,0.16));
  border-color: rgba(191,219,254,0.48);
}

.ea-shop-pack-hero-resources img,
.ea-shop-pack-hero-resources svg {
  width: 25px;
  height: 25px;
}

.ea-shop-pack-hero-resources span.keys img {
  padding: 4px;
  border-radius: 50%;
  background: #bfdbfe;
  box-sizing: border-box;
}

.ea-shop-pack-hero-resources b {
  font-size: 13px;
  line-height: 1;
}

.ea-shop-pack-hero-cosmetics {
  position: relative;
  height: auto;
  aspect-ratio: 2 / 1;
  display: block;
  padding: 0;
  background: linear-gradient(135deg, rgba(5,2,12,0.62), rgba(26,16,48,0.88));
}

.ea-shop-pack-cosmetic-frame {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  animation: ea-shop-pack-soft-in 0.36s ease both;
}

.ea-shop-pack-cosmetic-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255,255,255,0.72) 42%, rgba(255,255,255,0.2) 54%, transparent 72%);
}

.ea-shop-pack-hero-cosmetics.is-rotating .ea-shop-pack-cosmetic-frame::after {
  animation: ea-shop-pack-white-flash 0.7s ease;
}

.ea-shop-pack-bg-full {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: rgba(255,255,255,0.04);
}

.ea-shop-pack-bg-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, rgba(167,139,250,0.35), rgba(96,165,250,0.2));
}

.ea-shop-pack-avatar-corner {
  position: absolute;
  left: 10px;
  bottom: 10px;
  width: 52px;
  height: 52px;
  border-radius: 10px;
  border: 2px solid rgba(255,255,255,0.9);
  object-fit: cover;
  background: #2d1f52;
  box-shadow: 0 8px 16px rgba(0,0,0,0.32);
}

@keyframes ea-shop-pack-soft-in {
  from { opacity: 0.62; filter: brightness(1.65); }
  to { opacity: 1; filter: brightness(1); }
}

@keyframes ea-shop-pack-white-flash {
  0% { opacity: 0; transform: translateX(-38%); }
  18% { opacity: 0.9; }
  100% { opacity: 0; transform: translateX(42%); }
}

.ea-shop-pack-hero-card {
  position: relative;
  display: grid;
  place-items: center;
  height: 170px;
  padding: 12px;
  background:
    radial-gradient(circle at 50% 34%, rgba(191,219,254,0.28), transparent 42%),
    linear-gradient(145deg, rgba(5,2,12,0.42), rgba(26,16,48,0.82));
}

.ea-shop-pack-card-mode-card-only .ea-shop-pack-hero-card {
  height: 176px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: visible;
}

.ea-shop-pack-card-art {
  width: min(96px, 100%);
  aspect-ratio: 2 / 3;
  border-radius: 13px;
  overflow: hidden;
  background: rgba(96,165,250,0.14);
  box-shadow: 0 18px 30px rgba(0,0,0,0.48), 0 0 0 1px rgba(255,255,255,0.16);
  transform: rotate(-2deg);
}

.ea-shop-pack-card-mode-card-only .ea-shop-pack-card-art {
  width: min(112px, 100%);
  border-radius: 12px;
  background: transparent;
  box-shadow: 0 18px 30px rgba(0,0,0,0.36);
  transform: rotate(-1deg);
}

.ea-shop-pack-card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ea-shop-pack-card-art span {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #bfdbfe;
}

.ea-shop-pack-card-rarity {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  min-width: 0;
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(5,2,12,0.62);
  border: 1px solid rgba(191,219,254,0.24);
  color: #dbeafe;
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ea-shop-pack-card-showcase {
  display: grid;
  gap: 10px;
}

.ea-shop-pack-card-showcase .ea-shop-pack-hero-cosmetics {
  height: auto;
  aspect-ratio: 2 / 1;
}

.ea-shop-pack-card-line {
  min-width: 0;
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  padding: 8px;
  border-radius: 16px;
  background: rgba(5, 2, 12, 0.3);
  border: 1px solid color-mix(in srgb, var(--pack-accent) 32%, rgba(255,255,255,0.08));
}

.ea-shop-pack-card-art-inline {
  width: 82px;
  align-self: center;
  border-radius: 10px;
  box-shadow: 0 12px 22px rgba(0,0,0,0.38);
  transform: none;
}

.ea-shop-pack-card-line .ea-shop-pack-card-details {
  margin-top: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ea-shop-pack-card-copy {
  min-width: 0;
}

.ea-shop-pack-card-copy strong,
.ea-shop-pack-card-copy span,
.ea-shop-pack-card-copy em {
  display: block;
  min-width: 0;
}

.ea-shop-pack-card-copy strong {
  color: #fff;
  font-size: 12px;
  line-height: 1.08;
  font-weight: 900;
}

.ea-shop-pack-card-copy span,
.ea-shop-pack-card-copy em {
  margin-top: 4px;
  font-size: 9.8px;
  line-height: 1.18;
  color: #c4b8e8;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.ea-shop-pack-card-copy em {
  color: #bfdbfe;
  font-style: normal;
  -webkit-line-clamp: 4;
}

.ea-shop-pack-footer {
  position: absolute;
  left: 13px;
  right: 13px;
  bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.ea-shop-pack-buy {
  min-width: 0;
  min-height: 42px;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 13px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--pack-accent), var(--pack-accent-2));
  color: #120919;
  box-shadow: 0 10px 26px var(--pack-glow);
  font-weight: 900;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.ea-shop-pack-buy span,
.ea-shop-pack-buy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ea-shop-pack-buy span {
  font-size: 12px;
  text-transform: uppercase;
}

.ea-shop-pack-buy strong {
  color: #fff;
  font-size: 14px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.28);
}

.ea-shop-pack-buy:disabled {
  color: rgba(255,255,255,0.74);
  background: linear-gradient(135deg, rgba(122,111,160,0.62), rgba(74,61,106,0.72));
  box-shadow: none;
}

.ea-shop-pack-info {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border: 1px solid color-mix(in srgb, var(--pack-accent) 42%, rgba(255,255,255,0.12));
  border-radius: 14px;
  background: rgba(5, 2, 12, 0.42);
  color: #fff;
  font-family: Georgia, serif;
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.ea-shop-info-modal {
  position: fixed;
  inset: 0;
  z-index: 24000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: calc(16px + var(--ea-safe-top)) calc(14px + var(--ea-safe-right)) calc(16px + var(--ea-safe-bottom-soft)) calc(14px + var(--ea-safe-left));
  background: rgba(5, 2, 12, 0.86);
  backdrop-filter: blur(12px);
  animation: fadeIn 0.18s ease;
}

.ea-shop-info-sheet {
  --pack-accent: #a78bfa;
  --pack-accent-2: #60a5fa;
  --pack-glow: rgba(96, 165, 250, 0.28);
  width: 100%;
  max-width: 430px;
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  border-radius: 24px;
  border: 1px solid rgba(255,255,255,0.12);
  background:
    radial-gradient(circle at 78% 0%, rgba(167,139,250,0.18), transparent 32%),
    linear-gradient(180deg, rgba(26,16,48,0.98), rgba(13,8,27,0.99));
  box-shadow: 0 24px 80px rgba(0,0,0,0.64);
  padding: 16px;
}

.ea-shop-info-head {
  display: grid;
  grid-template-columns: minmax(0,1fr) 36px;
  gap: 10px;
  align-items: start;
  margin-bottom: 14px;
}

.ea-shop-info-head h3 {
  margin: 7px 0 5px;
  color: #fff;
  font-size: 22px;
  line-height: 1.03;
  font-weight: 1000;
}

.ea-shop-info-head p {
  margin: 0;
  color: #c4b8e8;
  font-size: 12px;
  line-height: 1.42;
}

.ea-shop-info-close {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  background: rgba(255,255,255,0.06);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.ea-shop-info-section {
  display: grid;
  gap: 8px;
  padding: 12px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.ea-shop-info-section h4 {
  margin: 0;
  color: #fff;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
  text-transform: uppercase;
}

.ea-shop-info-card-row {
  display: grid;
  grid-template-columns: 58px minmax(0,1fr);
  gap: 10px;
  padding: 9px;
  border-radius: 14px;
  background: rgba(255,255,255,0.055);
  border: 1px solid rgba(255,255,255,0.08);
}

.ea-shop-info-card-row img {
  width: 58px;
  aspect-ratio: 2 / 3;
  border-radius: 10px;
  object-fit: cover;
}

.ea-shop-info-card-row strong,
.ea-shop-info-card-row span,
.ea-shop-info-card-row em {
  display: block;
}

.ea-shop-info-card-row strong {
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.ea-shop-info-card-stats {
  margin-top: 6px;
}

.ea-shop-info-card-row .ea-shop-info-card-stats span {
  display: inline-flex;
  margin-top: 0;
  color: #fff;
}

.ea-shop-info-card-row span,
.ea-shop-info-card-row em {
  margin-top: 4px;
  color: #c4b8e8;
  font-size: 11px;
  line-height: 1.34;
}

.ea-shop-info-card-row em {
  color: #bfdbfe;
  font-style: normal;
}

.ea-shop-info-cosmetics,
.ea-shop-info-resources {
  display: grid;
  gap: 8px;
}

.ea-shop-info-cosmetics {
  grid-template-columns: repeat(2, minmax(0,1fr));
}

.ea-shop-info-cosmetic {
  min-width: 0;
  display: grid;
  grid-template-columns: 46px minmax(0,1fr);
  gap: 8px;
  align-items: center;
  padding: 8px;
  border-radius: 14px;
  background: rgba(255,255,255,0.055);
  border: 1px solid rgba(255,255,255,0.08);
}

.ea-shop-info-cosmetic img,
.ea-shop-info-cosmetic i {
  width: 46px;
  height: 46px;
  border-radius: 9px;
  object-fit: cover;
  background: rgba(167,139,250,0.14);
  display: grid;
  place-items: center;
  color: #ddd6fe;
  font-style: normal;
  font-weight: 900;
}

.ea-shop-info-cosmetic.background img {
  object-fit: contain;
  border-radius: 7px;
}

.ea-shop-info-cosmetic span {
  min-width: 0;
  color: #f0ecff;
  font-size: 11px;
  line-height: 1.2;
  font-weight: 800;
}

.ea-shop-info-cosmetic b {
  display: block;
  margin-bottom: 3px;
  color: #a78bfa;
  font-size: 9px;
  text-transform: uppercase;
}

.ea-shop-info-actions {
  position: sticky;
  bottom: -16px;
  padding-top: 10px;
  background: linear-gradient(180deg, transparent, rgba(13,8,27,0.99) 28%);
}

@media (max-width: 390px) {
  .ea-shop-pack-card {
    grid-template-columns: minmax(0, 1fr) 102px;
    min-height: 204px;
    padding: 12px;
  }
  .ea-shop-pack-variant-card {
    grid-template-columns: minmax(0, 1fr) 108px;
    min-height: 252px;
  }
  .ea-shop-pack-card-mode-card-cosmetic {
    grid-template-columns: 1fr;
    min-height: 420px;
  }
  .ea-shop-pack-card h3 {
    font-size: 19px;
  }
  .ea-shop-pack-hero-card {
    height: 160px;
    border-radius: 16px;
  }
  .ea-shop-pack-card-art {
    width: 86px;
  }
  .ea-shop-pack-card-mode-card-only .ea-shop-pack-card-art {
    width: 96px;
  }
  .ea-shop-pack-card-line {
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 8px;
  }
  .ea-shop-pack-card-art-inline {
    width: 74px;
  }
  .ea-shop-pack-footer {
    left: 12px;
    right: 12px;
  }
  .ea-shop-info-cosmetics {
    grid-template-columns: 1fr;
  }
}

.ea-shop-pass-card {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: linear-gradient(180deg, rgba(45, 31, 82, 0.94), rgba(26, 16, 48, 0.96));
  animation: ea-shop-pass-border-glow 2.4s ease-in-out infinite;
}

@keyframes ea-shop-pass-border-glow {
  0%, 100% { box-shadow: 0 0 0 rgba(0, 0, 0, 0), 0 0 40px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.32)), 0 0 80px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.18)); }
  50%      { box-shadow: 0 0 0 rgba(0, 0, 0, 0), 0 0 70px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.6)),  0 0 130px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.32)); }
}

.ea-shop-pass-card.ea-shop-mode-pass {
  --ea-shop-pass-a: rgba(255, 77, 46, 0.92);
  --ea-shop-pass-b: rgba(245, 146, 30, 0.5);
  --ea-shop-pass-glow: rgba(255, 215, 0, 0.55);
  --ea-shop-pass-solid-a: #ff4d2e;
  --ea-shop-pass-solid-b: #f5921e;
}

.ea-shop-pass-card.ea-shop-mode-ultra {
  --ea-shop-pass-a: rgba(255, 95, 162, 0.94);
  --ea-shop-pass-b: rgba(45, 212, 191, 0.58);
  --ea-shop-pass-glow: rgba(96, 165, 250, 0.6);
  --ea-shop-pass-solid-a: #ff5fa2;
  --ea-shop-pass-solid-b: #2dd4bf;
}

.ea-shop-pass-hero {
  min-height: 194px;
  padding: 15px 14px 12px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 78% 8%, var(--ea-shop-pass-glow), transparent 42%),
    linear-gradient(135deg, var(--ea-shop-pass-a), var(--ea-shop-pass-b));
  background-size: 220% 220%, 240% 240%;
  animation: ea-shop-pass-shimmer 2.6s ease-in-out infinite;
}

@keyframes ea-shop-pass-shimmer {
  0%, 100% { background-position: 0% 0%, 0% 50%; }
  50%      { background-position: 100% 0%, 100% 50%; }
}

@media (prefers-reduced-motion: reduce) {
  .ea-shop-pass-card,
  .ea-shop-pass-hero {
    animation: none;
  }
}

.ea-shop-pass-tabs {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 12px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  background: rgba(5, 2, 12, 0.35);
}

.ea-shop-pass-tabs button {
  min-height: 36px;
  border: 0;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.68);
  background: transparent;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.ea-shop-pass-tabs button.active {
  color: #fff;
  background: linear-gradient(135deg, var(--ea-shop-pass-solid-a), var(--ea-shop-pass-solid-b));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 8px 22px rgba(0, 0, 0, 0.32),
    0 0 16px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.55));
  animation: ea-shop-tab-pulse 2.6s ease-in-out infinite;
}

@keyframes ea-shop-tab-pulse {
  0%, 100% { filter: brightness(1) saturate(1); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 8px 22px rgba(0, 0, 0, 0.32), 0 0 16px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.55)); }
  50%      { filter: brightness(1.15) saturate(1.2); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 8px 26px rgba(0, 0, 0, 0.4), 0 0 28px var(--ea-shop-pass-glow, rgba(255, 215, 0, 0.85)); }
}

.ea-shop-pass-headline {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.ea-shop-pass-mark {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 24px;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.ea-shop-pass-headline h3 {
  margin: 0;
  color: #fff;
  font-size: 28px;
  line-height: 0.9;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  text-shadow: 0 4px 14px rgba(0, 0, 0, 0.26);
}

.ea-shop-pass-headline p {
  margin: 6px 0 0;
  max-width: 230px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 12px;
  line-height: 1.35;
  font-weight: 700;
}

.ea-shop-pass-active {
  position: relative;
  z-index: 2;
  display: inline-flex;
  margin-top: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(5, 2, 12, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.ea-shop-value-strip {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 14px;
}

.ea-shop-value {
  min-height: 54px;
  padding: 8px 6px;
  border-radius: 14px;
  background: rgba(5, 2, 12, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.16);
  text-align: center;
}

.ea-shop-value strong {
  display: block;
  color: #fff;
  font-size: 17px;
  line-height: 1;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.ea-shop-value span {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 9px;
  line-height: 1.1;
  font-weight: 700;
}

.ea-shop-benefits {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 12px;
}

.ea-shop-benefit {
  min-height: 61px;
  border-radius: 14px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
}

.ea-shop-benefit strong {
  display: block;
  color: #f0ecff;
  font-size: 12px;
  line-height: 1.1;
  font-weight: 900;
}

.ea-shop-benefit span {
  display: block;
  margin-top: 4px;
  color: #c4b8e8;
  font-size: 10px;
  line-height: 1.25;
}

.ea-shop-compare {
  margin: 0 12px 12px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(5, 2, 12, 0.28);
}

.ea-shop-compare-row {
  display: grid;
  grid-template-columns: 1.25fr 0.72fr 0.72fr;
  align-items: center;
  min-height: 34px;
  border-top: 1px solid rgba(255, 255, 255, 0.075);
  color: #c4b8e8;
  font-size: 11px;
  font-weight: 700;
}

.ea-shop-compare-row:first-child {
  border-top: 0;
  color: #fff;
  background: rgba(255, 255, 255, 0.045);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ea-shop-compare-row > div {
  padding: 8px;
}

.ea-shop-compare-row > div:nth-child(2),
.ea-shop-compare-row > div:nth-child(3) {
  text-align: center;
  border-left: 1px solid rgba(255, 255, 255, 0.075);
}

.ea-shop-pass-actions {
  display: grid;
  grid-template-columns: minmax(0, 220px);
  justify-content: center;
  gap: 8px;
  padding: 0 12px 13px;
}

.ea-shop-pass-actions.has-secondary {
  grid-template-columns: repeat(2, minmax(0, 220px));
}

.ea-shop-pass-actions button {
  min-height: 42px;
  border: 0;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--ea-shop-pass-solid-a), var(--ea-shop-pass-solid-b));
  font-weight: 900;
  font-size: 13px;
}

.ea-shop-pass-actions button.secondary {
  border: 1px dashed rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
  color: #c4b8e8;
}

.ea-shop-case-grid,
.ea-shop-gem-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.ea-shop-currency-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.ea-shop-case-card,
.ea-shop-currency-card,
.ea-shop-particle-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(122, 111, 160, 0.42);
  border-radius: 17px;
  background: linear-gradient(180deg, rgba(45, 31, 82, 0.96), rgba(26, 16, 48, 0.96));
}

.ea-shop-case-card {
  min-height: 116px;
  padding: 12px;
  display: grid;
  grid-template-columns: 66px 1fr;
  gap: 8px;
  align-items: center;
}

.ea-shop-case-card.popular {
  border-color: rgba(245, 146, 30, 0.72);
}

.ea-shop-case-card img {
  width: 72px;
  transform: translateX(-10px);
  filter: drop-shadow(0 10px 12px rgba(0, 0, 0, 0.38));
}

.ea-shop-case-card strong,
.ea-shop-currency-card strong {
  display: block;
  color: #f0ecff;
  font-size: 17px;
  line-height: 1;
  font-weight: 900;
}

.ea-shop-case-card span,
.ea-shop-currency-card span {
  display: block;
  margin-top: 5px;
  color: #c4b8e8;
  font-size: 11px;
  font-weight: 700;
}

.ea-shop-mini-buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  margin-top: 9px;
  padding: 0 10px;
  border-radius: 10px;
  background: linear-gradient(135deg, #5b3fa0, #7c5cbf);
  box-shadow: none;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
}

.ea-shop-currency-card {
  min-height: 116px;
  padding: 14px 10px;
  text-align: center;
}

.ea-shop-currency-card.featured {
  border-color: rgba(245, 146, 30, 0.62);
  background:
    radial-gradient(circle at 50% 0%, rgba(245, 146, 30, 0.2), transparent 58%),
    linear-gradient(180deg, rgba(45, 31, 82, 0.96), rgba(26, 16, 48, 0.96));
}

.ea-shop-currency-card small {
  display: block;
  margin-top: 5px;
  color: #7a6fa0;
  font-size: 9px;
  font-weight: 700;
}

.ea-shop-discount,
.ea-shop-once {
  position: absolute;
  top: 8px;
  right: 8px;
  border-radius: 7px;
  padding: 2px 6px;
  color: #fff;
  background: #ef4444;
  font-size: 10px;
  font-weight: 900;
}

.ea-shop-once {
  background: #f5921e;
}

.ea-shop-particles-panel {
  border: 1px solid rgba(96, 165, 250, 0.34);
  border-radius: 22px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(96, 165, 250, 0.09), transparent 34%),
    rgba(26, 16, 48, 0.96);
}

.ea-shop-particles-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ea-shop-timer {
  padding: 7px 9px;
  border-radius: 11px;
  background: rgba(96, 165, 250, 0.12);
  border: 1px solid rgba(96, 165, 250, 0.24);
  color: #bfdbfe;
  font-size: 11px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.ea-shop-particles-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding: 10px;
}

.ea-shop-particle-card {
  min-height: 214px;
  display: flex;
  flex-direction: column;
  border-color: var(--ea-shop-rarity);
  background:
    radial-gradient(circle at 50% 0%, var(--ea-shop-rarity-glow), transparent 54%),
    linear-gradient(180deg, rgba(45, 31, 82, 0.78), rgba(26, 16, 48, 0.98) 58%),
    linear-gradient(180deg, rgba(45, 31, 82, 0.96), rgba(26, 16, 48, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 12px 24px rgba(0, 0, 0, 0.22);
}

.ea-shop-particle-card.ea-shop-featured-particle {
  min-height: 168px;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 132px 1fr;
  align-items: stretch;
}

.ea-shop-particle-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), transparent 30%),
    radial-gradient(circle at 90% 12%, var(--ea-shop-rarity-glow), transparent 26%);
  opacity: 0.5;
  pointer-events: none;
}

.ea-shop-particle-card::after {
  content: attr(data-rarity-title);
  position: absolute;
  z-index: 2;
  top: 8px;
  right: 9px;
  padding: 3px 5px;
  border-radius: 999px;
  background: rgba(5, 2, 12, 0.48);
  color: var(--ea-shop-rarity);
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.42);
}

.ea-shop-particle-art {
  position: relative;
  height: 116px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), transparent),
    radial-gradient(circle at 50% 22%, rgba(255, 255, 255, 0.22), transparent 62%);
}

.ea-shop-particle-card:not(.ea-shop-featured-particle) .ea-shop-particle-art {
  box-sizing: border-box;
  height: 130px;
  padding-top: 24px;
}

.ea-shop-featured-particle .ea-shop-particle-art {
  height: auto;
  min-height: 168px;
}

.ea-shop-particle-art img {
  position: relative;
  z-index: 1;
  width: 78px;
  border-radius: 10px;
  box-shadow: 0 14px 20px rgba(0, 0, 0, 0.48);
  transform: rotate(-2deg);
}

.ea-shop-featured-particle .ea-shop-particle-art img {
  width: 94px;
  transform: rotate(-4deg);
}

.ea-shop-particle-body {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 10px;
}

.ea-shop-particle-name {
  min-height: 28px;
  color: #f0ecff;
  font-size: 13px;
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 0;
}

.ea-shop-featured-particle .ea-shop-particle-name {
  min-height: auto;
  padding-right: 28px;
  font-size: 19px;
}

.ea-shop-particle-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 6px;
  color: #c4b8e8;
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.ea-shop-progress {
  height: 6px;
  margin-top: 7px;
  border-radius: 99px;
  background: rgba(5, 2, 12, 0.3);
  overflow: hidden;
}

.ea-shop-progress i {
  display: block;
  width: var(--ea-shop-progress);
  height: 100%;
  background: linear-gradient(90deg, var(--ea-shop-rarity), #f5921e);
}

.ea-shop-particle-cost {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-top: 8px;
  color: #c4b8e8;
  font-size: 10px;
  font-weight: 900;
}

.ea-shop-particle-cost span {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  border-radius: 9px;
  background: rgba(5, 2, 12, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ea-shop-particle-card .ea-shop-mini-buy {
  width: 100%;
  margin-top: auto;
  background: linear-gradient(135deg, var(--ea-shop-rarity), #5b3fa0);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

@media (max-width: 370px) {
  .ea-shop-root {
    padding-left: 10px;
    padding-right: 10px;
  }

  .ea-shop-bundle-copy {
    width: 64%;
  }

  .ea-shop-currency-grid {
    grid-template-columns: 1fr 1fr;
  }

  .ea-shop-particle-card.ea-shop-featured-particle {
    grid-template-columns: 118px 1fr;
  }
}

/* ─── Loading Splash ─── */
#loading-screen {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: #0a0514;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto auto auto;
  grid-template-areas:
    "vlogo"
    "hero"
    "gamelogo"
    "bottom"
    "copyright";
  align-items: center;
  justify-items: center;
  overflow: hidden;
  transition: opacity 0.5s ease;
  pointer-events: all;
  padding: env(safe-area-inset-top, 16px) 16px env(safe-area-inset-bottom, 16px);
  min-height: 100vh;
  min-height: 100dvh;
  height: 100dvh;
  box-sizing: border-box;
}

#loading-screen.loading-done {
  opacity: 0;
  pointer-events: none;
}

/* ─── Background layers ─── */
.loading-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.loading-bg-layer {
  position: absolute;
  width: 200%;
  height: 200%;
  top: -50%;
  left: -50%;
  filter: blur(50px);
  pointer-events: none;
  animation: loadingBgDrift 18s ease-in-out infinite;
}

.loading-bg-layer:nth-child(1) {
  background: radial-gradient(circle at 40% 55%, rgba(148, 80, 240, 0.3) 0%, transparent 55%);
  animation-delay: 0s;
}

.loading-bg-layer:nth-child(2) {
  background: radial-gradient(circle at 55% 40%, rgba(100, 150, 255, 0.2) 0%, transparent 50%);
  animation-delay: -6s;
  animation-duration: 22s;
}

.loading-bg-layer:nth-child(3) {
  background: radial-gradient(circle at 45% 65%, rgba(230, 130, 200, 0.18) 0%, transparent 50%);
  animation-delay: -12s;
  animation-duration: 20s;
}

@keyframes loadingBgDrift {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33%  { transform: translate(3%, -2%) rotate(3deg); }
  66%  { transform: translate(-2%, 3%) rotate(-3deg); }
}

/* ─── Stars ─── */
.loading-stars {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.loading-stars .star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 0 5px rgba(180, 140, 255, 0.9), 0 0 10px rgba(100, 150, 255, 0.5);
  animation: starTwinkle 3s ease-in-out infinite;
}

.loading-stars .star:nth-child(1)  { top: 8%;  left: 12%; animation-delay: 0s; }
.loading-stars .star:nth-child(2)  { top: 18%; left: 82%; animation-delay: 0.5s; }
.loading-stars .star:nth-child(3)  { top: 28%; left: 40%; animation-delay: 1s; }
.loading-stars .star:nth-child(4)  { top: 38%; left: 18%; animation-delay: 1.5s; }
.loading-stars .star:nth-child(5)  { top: 48%; left: 72%; animation-delay: 2s; }
.loading-stars .star:nth-child(6)  { top: 58%; left: 30%; animation-delay: 0.3s; }
.loading-stars .star:nth-child(7)  { top: 68%; left: 88%; animation-delay: 0.8s; }
.loading-stars .star:nth-child(8)  { top: 78%; left: 50%; animation-delay: 1.2s; }
.loading-stars .star:nth-child(9)  { top: 14%; left: 55%; animation-delay: 1.8s; }
.loading-stars .star:nth-child(10) { top: 24%; left: 25%; animation-delay: 2.2s; }
.loading-stars .star:nth-child(11) { top: 34%; left: 78%; animation-delay: 0.7s; }
.loading-stars .star:nth-child(12) { top: 44%; left: 48%; animation-delay: 1.3s; }
.loading-stars .star:nth-child(13) { top: 54%; left: 15%; animation-delay: 1.9s; }
.loading-stars .star:nth-child(14) { top: 64%; left: 92%; animation-delay: 0.4s; }
.loading-stars .star:nth-child(15) { top: 74%; left: 35%; animation-delay: 2.5s; }

@keyframes starTwinkle {
  0%, 100% { opacity: 0.25; transform: scale(1); }
  50%      { opacity: 1;    transform: scale(1.6); }
}

/* ─── Particles ─── */
.loading-particles {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.loading-particles .particle {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(180, 120, 250, 0.9), rgba(100, 150, 255, 0.4));
  box-shadow: 0 0 12px rgba(180, 120, 250, 0.7);
  animation: particleFloat 10s ease-in-out infinite;
}

.loading-particles .particle:nth-child(1)  { left: 5%;  animation-delay: 0s; }
.loading-particles .particle:nth-child(2)  { left: 14%; animation-delay: 0.8s; }
.loading-particles .particle:nth-child(3)  { left: 23%; animation-delay: 1.6s; }
.loading-particles .particle:nth-child(4)  { left: 32%; animation-delay: 0.4s; }
.loading-particles .particle:nth-child(5)  { left: 41%; animation-delay: 1.2s; }
.loading-particles .particle:nth-child(6)  { left: 50%; animation-delay: 2s; }
.loading-particles .particle:nth-child(7)  { left: 59%; animation-delay: 0.6s; }
.loading-particles .particle:nth-child(8)  { left: 68%; animation-delay: 1.4s; }
.loading-particles .particle:nth-child(9)  { left: 77%; animation-delay: 2.2s; }
.loading-particles .particle:nth-child(10) { left: 86%; animation-delay: 0.3s; }

@keyframes particleFloat {
  0%   { transform: translateY(105vh) translateX(0) scale(0.2); opacity: 0; }
  10%  { opacity: 1; }
  50%  { transform: translateY(45vh) translateX(20px) scale(1); opacity: 0.8; }
  90%  { opacity: 1; }
  100% { transform: translateY(-5vh) translateX(-15px) scale(0.4); opacity: 0; }
}

/* ─── V logo (top) ─── */
.loading-v-logo {
  grid-area: vlogo;
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: max(6px, 1vh);
}

.loading-v-logo img {
  width: clamp(28px, 9vw, 52px);
  max-height: 8vh;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 14px rgba(180, 140, 255, 0.7)) drop-shadow(0 0 6px rgba(0,0,0,0.5));
}

/* ─── Central glow ring ─── */
.loading-hero {
  grid-area: hero;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.loading-hero-ring {
  width: clamp(90px, 32vw, 190px);
  height: clamp(90px, 32vw, 190px);
  border-radius: 50%;
  border: 2px solid rgba(160, 120, 240, 0.4);
  box-shadow:
    0 0 40px rgba(140, 100, 240, 0.35),
    0 0 100px rgba(120, 80, 230, 0.18),
    inset 0 0 40px rgba(140, 100, 240, 0.12);
  animation: heroRingPulse 3s ease-in-out infinite;
  position: relative;
}

.loading-hero-ring-outer {
  position: absolute;
  width: clamp(110px, 38vw, 230px);
  height: clamp(110px, 38vw, 230px);
  border-radius: 50%;
  border: 1px solid rgba(160, 120, 240, 0.18);
  box-shadow: 0 0 60px rgba(140, 100, 240, 0.15);
  animation: heroRingPulse 3s ease-in-out infinite;
  animation-delay: -1s;
}

.loading-hero-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle, #c0a0ff, #6a4fbf);
  box-shadow: 0 0 14px #9c7de0, 0 0 28px #6a4fbf;
  animation: heroDotOrbit 4s linear infinite;
}

@keyframes heroRingPulse {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50%      { transform: scale(1.06); opacity: 1; }
}

@keyframes heroDotOrbit {
  0%   { top: 0; left: 50%; transform: translate(-50%, -50%); }
  25%  { top: 50%; left: 100%; transform: translate(-50%, -50%); }
  50%  { top: 100%; left: 50%; transform: translate(-50%, -50%); }
  75%  { top: 50%; left: 0; transform: translate(-50%, -50%); }
  100% { top: 0; left: 50%; transform: translate(-50%, -50%); }
}

/* ─── Game logo ─── */
.loading-game-logo {
  grid-area: gamelogo;
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: end;
}

.loading-game-logo img {
  width: min(72vw, 280px);
  max-height: 20vh;
  height: auto;
  object-fit: contain;
  filter:
    drop-shadow(0 0 14px rgba(0,0,0,0.9))
    drop-shadow(0 0 28px rgba(160, 120, 250, 0.8))
    drop-shadow(0 0 55px rgba(100, 140, 255, 0.5));
  animation: logoFloat 4s ease-in-out infinite;
}

@keyframes logoFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}

/* ─── Bottom status + progress ─── */
.loading-bottom {
  grid-area: bottom;
  position: relative;
  z-index: 3;
  width: min(100%, 560px);
  max-width: 100%;
  padding: 12px 20px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.loading-status-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: baseline;
}

.loading-status-text {
  font-family: 'Exo 2', sans-serif;
  font-size: clamp(12px, 3.5vw, 15px);
  font-weight: 600;
  color: rgba(240, 236, 255, 0.85);
  text-shadow: 0 0 10px rgba(160, 130, 255, 0.5);
  letter-spacing: 0.3px;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.loading-percentage {
  font-family: 'Exo 2', sans-serif;
  font-size: clamp(36px, 12vw, 68px);
  font-weight: 900;
  color: #fff;
  line-height: 0.9;
  text-shadow:
    0 0 12px rgba(255, 255, 255, 0.5),
    0 0 30px rgba(160, 130, 255, 0.6);
  letter-spacing: 1px;
  flex-shrink: 0;
}

.loading-progress-track {
  width: 100%;
  height: clamp(6px, 1.6vh, 10px);
  background: rgba(90, 55, 140, 0.35);
  border-radius: 10px;
  overflow: visible;
  position: relative;
  border: 1px solid rgba(160, 120, 240, 0.3);
}

.loading-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 10px;
  background: linear-gradient(90deg, #f5931e, #ffb347, #fbbf24);
  box-shadow:
    0 0 12px rgba(245, 147, 30, 0.7),
    0 0 25px rgba(245, 147, 30, 0.3);
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.loading-progress-fill::after {
  content: '';
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow:
    0 0 10px rgba(255, 255, 255, 0.9),
    0 0 20px rgba(245, 147, 30, 0.6);
  border: 2px solid #f5931e;
}

.loading-progress-shimmer {
  position: absolute;
  inset: 0;
  border-radius: 10px;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.25) 50%, transparent 100%);
  animation: shimmerMove 2s ease-in-out infinite;
  pointer-events: none;
}

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

/* ─── Bottom V logo ─── */
.loading-copyright {
  grid-area: copyright;
  position: relative;
  z-index: 3;
  padding-bottom: max(8px, 1vh);
  opacity: 0.7;
  animation: copyrightPulse 3s ease-in-out infinite;
}

.loading-copyright img {
  width: clamp(22px, 7vw, 38px);
  max-height: 6vh;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(160, 140, 255, 0.5));
}

@keyframes copyrightPulse {
  0%, 100% { opacity: 0.5; }
  50%      { opacity: 0.85; }
}

/* ─── Responsive: short screens ─── */
@media (max-height: 700px) {
  #loading-screen {
    grid-template-rows: auto minmax(0, 1fr) auto auto auto;
    padding: env(safe-area-inset-top, 8px) 16px env(safe-area-inset-bottom, 8px);
  }
  .loading-hero-ring {
    width: clamp(70px, 26vw, 130px);
    height: clamp(70px, 26vw, 130px);
  }
  .loading-hero-ring-outer {
    width: clamp(90px, 32vw, 160px);
    height: clamp(90px, 32vw, 160px);
  }
  .loading-game-logo img {
    max-height: 16vh;
    width: min(60vw, 220px);
  }
  .loading-v-logo {
    padding-top: max(2px, 0.5vh);
  }
  .loading-bottom {
    gap: 6px;
  }
}

@media (max-height: 560px) {
  #loading-screen {
    grid-template-rows: auto minmax(0, 1fr) auto auto auto;
    padding: env(safe-area-inset-top, 4px) 16px env(safe-area-inset-bottom, 4px);
  }
  .loading-v-logo {
    display: none;
  }
  .loading-hero-ring {
    width: clamp(50px, 20vw, 90px);
    height: clamp(50px, 20vw, 90px);
  }
  .loading-hero-ring-outer {
    width: clamp(65px, 25vw, 115px);
    height: clamp(65px, 25vw, 115px);
  }
  .loading-game-logo img {
    max-height: 12vh;
    width: min(50vw, 180px);
  }
  .loading-copyright {
    display: none;
  }
  .loading-bottom {
    gap: 4px;
  }
  .loading-percentage {
    font-size: clamp(26px, 9vw, 44px);
  }
  .loading-status-text {
    font-size: clamp(11px, 3vw, 13px);
  }
  .loading-progress-track {
    height: clamp(4px, 1.2vh, 7px);
  }
}

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

#app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 100%;
  margin: 0 auto;
  background: var(--chibi-bg);
  transition: opacity 0.4s ease, filter 0.4s ease;
}

body.case-opening-active {
  overflow: hidden;
}

body.case-opening-active #app {
  opacity: 0;
  filter: blur(35px) scale(1.03);
  pointer-events: none;
}

/* Верхняя панель */
.top-bar {
  background: linear-gradient(180deg, rgba(45, 27, 78, 0.95) 0%, rgba(26, 15, 46, 0.95) 100%);
  backdrop-filter: blur(10px);
  border-bottom: 3px solid var(--chibi-border);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  position: sticky;
  top: 0;
  z-index: 100;
  border-radius: 0 0 20px 20px;
  position: relative;
}

.top-bar.extrapass-active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 80px;
  background: linear-gradient(90deg, var(--chibi-red) 0%, var(--chibi-orange) 50%, rgba(45, 27, 78, 0.95) 100%);
  border-radius: 0 0 0 20px;
  z-index: -1;
}

.player-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.player-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border: 4px solid var(--chibi-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 20px;
  color: var(--chibi-bg);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
  position: relative;
  overflow: visible;
  transition: all 0.3s ease;
  cursor: pointer;
}

.player-avatar:active {
  transform: scale(0.95);
}

.player-avatar.extrapass-active {
  border: 4px solid var(--chibi-extrapass);
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.6), 0 0 30px rgba(245, 158, 11, 0.3);
  animation: extrapass-glow 2s ease-in-out infinite;
}

@keyframes extrapass-glow {
  0%, 100% {
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.6), 0 0 30px rgba(245, 158, 11, 0.3);
  }
  50% {
    box-shadow: 0 4px 25px rgba(245, 158, 11, 0.8), 0 0 40px rgba(245, 158, 11, 0.5);
  }
}

.player-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}


.extrapass-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: var(--chibi-extrapass);
  color: var(--chibi-bg);
  border: 2px solid var(--chibi-bg);
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  z-index: 3;
  animation: pulse 1.5s ease-in-out infinite;
}

.rocket-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  z-index: 4;
  pointer-events: none;
  animation: float 2s ease-in-out infinite;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

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

.player-details {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.player-name-wrapper {
  display: flex;
  align-items: center;
  gap: 6px;
}

.player-name {
  font-weight: bold;
  font-size: 18px;
  color: var(--chibi-text);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

.player-title {
  font-size: 14px;
  color: var(--chibi-gold);
  font-weight: 500;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.resources-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.resources-bar {
  display: flex;
  gap: 8px;
  align-items: center;
}

.resource-item {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(192, 132, 252, 0.2);
  padding: 6px 10px;
  border-radius: 16px;
  border: 2px solid var(--chibi-border);
  font-size: 14px;
  font-weight: bold;
  backdrop-filter: blur(5px);
}

.resource-item:first-child {
  background: rgba(255, 215, 0, 0.3);
  border-color: var(--chibi-gold);
  box-shadow: 0 0 10px rgba(251, 191, 36, 0.4);
}

.resource-icon {
  font-size: 18px;
}

.menu-button {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  position: relative;
}

.menu-button:active {
  transform: scale(0.95);
  background: rgba(192, 132, 252, 0.3);
}

/* Индикатор непрочитанных уведомлений на кнопке меню */
.menu-notification-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 2px 8px rgba(239, 68, 68, 0.6),
    0 0 12px rgba(239, 68, 68, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  z-index: 10;
  animation: notificationPulse 2s ease-in-out infinite;
  line-height: 1;
  letter-spacing: 0;
}

@keyframes notificationPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 
      0 2px 8px rgba(239, 68, 68, 0.6),
      0 0 12px rgba(239, 68, 68, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.3);
  }
  50% {
    transform: scale(1.1);
    box-shadow: 
      0 3px 12px rgba(239, 68, 68, 0.8),
      0 0 16px rgba(239, 68, 68, 0.6),
      inset 0 1px 0 rgba(255, 255, 255, 0.4);
  }
}

/* Меню */
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  animation: fadeIn 0.3s ease;
}

.menu-panel {
  width: 100%;
  max-height: 60vh;
  background: linear-gradient(180deg, var(--chibi-card) 0%, var(--chibi-bg) 100%);
  border-top: 3px solid var(--chibi-border);
  border-radius: 24px 24px 0 0;
  padding: 20px;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--chibi-border);
}

.menu-header h3 {
  font-size: 22px;
  color: var(--chibi-text);
}

.menu-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--chibi-border);
  background: rgba(255, 255, 255, 0.1);
  color: var(--chibi-text);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.menu-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  color: var(--chibi-text);
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  width: 100%;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.menu-item:active {
  transform: scale(0.98);
  background: rgba(192, 132, 252, 0.2);
}

.menu-item-icon {
  font-size: 24px;
}

.menu-item-row {
  display: flex;
  gap: 8px;
  width: 100%;
}

.menu-item-half {
  flex: 1;
  width: auto;
}

/* Модальные окна */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
  z-index: 350;
  padding: 20px;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.3s ease;
}

/* Экран загрузки кейсов */
.case-loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26, 15, 46, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease-in;
}

.case-loading-content {
  text-align: center;
  padding: 40px;
  max-width: 400px;
  width: 90%;
}

.case-loading-icon {
  font-size: 80px;
  margin-bottom: 30px;
  animation: caseLoadingPulse 2s ease-in-out infinite;
  filter: drop-shadow(0 0 20px rgba(96, 165, 250, 0.5));
}

@keyframes caseLoadingPulse {
  0%, 100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
  50% {
    transform: scale(1.15) rotate(5deg);
    opacity: 0.9;
  }
}

.case-loading-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid rgba(96, 165, 250, 0.2);
  border-top-color: #60a5fa;
  border-radius: 50%;
  margin: 0 auto 30px;
  animation: caseLoadingSpin 1s linear infinite;
}

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

.case-loading-text {
  font-size: 20px;
  font-weight: 500;
  color: var(--chibi-text);
  margin-bottom: 20px;
  min-height: 30px;
}

.case-loading-progress {
  width: 100%;
  height: 8px;
  background: rgba(96, 165, 250, 0.2);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 15px;
  position: relative;
}

.case-loading-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #60a5fa, #c084fc, #ff9ec8);
  border-radius: 4px;
  width: 0%;
  transition: width 0.3s ease;
  position: relative;
  overflow: hidden;
}

.case-loading-progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  animation: caseLoadingShine 1.5s infinite;
}

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

.case-loading-status {
  font-size: 16px;
  color: var(--chibi-text-muted);
  font-weight: 500;
}

.case-opening-overlay {
  padding: 0;
  background: radial-gradient(circle at 30% 10%, rgba(123, 67, 255, 0.45), transparent 55%),
              radial-gradient(circle at 70% 30%, rgba(255, 99, 186, 0.35), transparent 65%),
              radial-gradient(circle at 50% 80%, rgba(255, 214, 126, 0.3), transparent 60%),
              #030013;
  z-index: 1200;
  overflow: hidden;
}

.case-opening-overlay::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 180px 180px;
  opacity: 0.3;
  animation: starsDrift 20s linear infinite;
  pointer-events: none;
}

@keyframes starsDrift {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-180px, -120px, 0); }
}

.case-opening-lights {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.case-light {
  display: block;
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.45;
  animation: caseLightPulse 16s ease-in-out infinite;
}

.case-light-1 {
  top: 8%;
  left: 15%;
  background: radial-gradient(circle, rgba(99, 179, 237, 0.7), transparent 65%);
  animation-delay: 0s;
}

.case-light-2 {
  bottom: 4%;
  left: 25%;
  background: radial-gradient(circle, rgba(236, 72, 153, 0.7), transparent 70%);
  animation-delay: 3s;
}

.case-light-3 {
  top: 18%;
  right: 12%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.75), transparent 65%);
  animation-delay: 6s;
}

.case-light-4 {
  bottom: -5%;
  right: 20%;
  background: radial-gradient(circle, rgba(74, 222, 128, 0.6), transparent 60%);
  animation-delay: 9s;
}

@keyframes caseLightPulse {
  0%, 100% { transform: scale(0.8) translateY(0); opacity: 0.4; }
  50% { transform: scale(1.4) translateY(-40px); opacity: 0.8; }
}

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

.modal-content {
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  background: linear-gradient(135deg, var(--chibi-card) 0%, var(--chibi-bg) 100%);
  border: 3px solid var(--chibi-border);
  border-radius: 24px;
  overflow: hidden;
  animation: scaleIn 0.3s ease;
  display: flex;
  flex-direction: column;
}

@keyframes scaleIn {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.1);
}

.modal-header h2 {
  font-size: 22px;
  color: var(--chibi-text);
}

.modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--chibi-border);
  background: rgba(255, 255, 255, 0.1);
  color: var(--chibi-text);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.case-opening-header .modal-close {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.case-opening-header .modal-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.modal-body {
  padding: 20px;
  max-height: calc(90vh - 140px);
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 16px 20px;
  border-top: 2px solid var(--chibi-border);
  display: flex;
  justify-content: center;
}

.setting-group {
  margin-bottom: 24px;
}

.setting-group-title {
  font-size: 18px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--chibi-border);
}

.setting-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  margin-bottom: 8px;
}

.setting-item.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.setting-label {
  flex: 1;
  font-size: 14px;
  color: var(--chibi-text);
}

.toggle-switch {
  width: 50px;
  height: 28px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid var(--chibi-border);
  position: relative;
  cursor: pointer;
  transition: all 0.3s;
}

.toggle-switch.active {
  background: var(--chibi-purple);
  border-color: var(--chibi-purple);
}

.toggle-switch::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: white;
  top: 1px;
  left: 1px;
  transition: all 0.3s;
}

.toggle-switch.active::after {
  left: 25px;
}

.extrapass-promo {
  margin-top: 16px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(245, 158, 11, 0.1));
  border: 2px solid var(--chibi-extrapass);
  border-radius: 12px;
  text-align: center;
}

.extrapass-promo-text {
  font-size: 14px;
  color: var(--chibi-text);
  margin-bottom: 12px;
}

.extrapass-promo-btn {
  padding: 10px 20px;
  background: var(--chibi-extrapass);
  color: var(--chibi-bg);
  border: none;
  border-radius: 12px;
  font-weight: bold;
  cursor: pointer;
}

.ads-place-btn {
  margin-top: 8px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--chibi-border);
  border-radius: 8px;
  color: var(--chibi-text-muted);
  font-size: 12px;
  cursor: pointer;
  width: 100%;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  margin-bottom: 12px;
}

.info-label {
  font-weight: bold;
  color: var(--chibi-text-muted);
}

.info-value {
  flex: 1;
  color: var(--chibi-text);
  font-family: monospace;
}

.copy-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.info-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.info-link {
  display: block;
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  text-decoration: none;
  text-align: center;
  font-weight: 500;
  transition: all 0.2s;
}

.info-link:active {
  transform: scale(0.98);
  background: rgba(192, 132, 252, 0.2);
}

.support-link {
  display: block;
  padding: 16px;
  background: var(--chibi-purple);
  color: var(--chibi-text);
  text-align: center;
  border-radius: 12px;
  text-decoration: none;
  font-weight: bold;
  margin-top: 16px;
}

/* Основной контент */
.content-area {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  position: relative;
}

.section {
  display: none;
  animation: fadeIn 0.3s ease-in;
  opacity: 0;
  transform: translateX(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.section.active {
  display: block;
  opacity: 1;
  transform: translateX(0);
}

.section.slide-out {
  animation: slideOut 0.3s ease-out;
}

.section.slide-in {
  animation: slideIn 0.3s ease-in;
}

@keyframes slideOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(-20px);
  }
}

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

.section-title {
  font-size: 26px;
  font-weight: bold;
  margin-bottom: 20px;
  color: var(--chibi-pink);
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
}

.arena-title-wrapper {
  position: relative;
  text-align: center;
  margin-bottom: 20px;
  padding: 12px 0;
}

.section-title.arena-title {
  font-size: 38px;
  text-align: center;
  margin: 0;
  letter-spacing: 4px;
  text-transform: uppercase;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #ff9ec8 0%, #c084fc 50%, #ff9ec8 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 3s ease infinite;
  filter: drop-shadow(0 0 20px rgba(192, 132, 252, 0.6));
  text-shadow: 0 0 30px rgba(255, 158, 200, 0.8), 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.section-title.arena-title .arena-title-text {
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
  text-shadow: 0 0 20px rgba(192, 132, 252, 0.8), 0 0 40px rgba(255, 158, 200, 0.6), 2px 2px 8px rgba(0, 0, 0, 0.9);
}

/* ====== TURN INDICATOR & TIMER ====== */
.turn-indicator-container {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.turn-indicator-plaque {
  flex: 1;
  min-width: 220px;
  background: rgba(17, 12, 35, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--chibi-text);
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.turn-indicator-plaque.player-turn {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.25), rgba(96, 165, 250, 0.05));
  border-color: rgba(96, 165, 250, 0.5);
  box-shadow: 0 0 24px rgba(96, 165, 250, 0.4);
}

.turn-indicator-plaque.opponent-turn {
  background: linear-gradient(135deg, rgba(240, 82, 95, 0.25), rgba(240, 82, 95, 0.05));
  border-color: rgba(240, 82, 95, 0.5);
  box-shadow: 0 0 24px rgba(240, 82, 95, 0.35);
}

.turn-indicator-plaque.turn-expired {
  background: rgba(58, 9, 20, 0.9);
  border-color: rgba(239, 68, 68, 0.65);
  box-shadow: 0 0 28px rgba(239, 68, 68, 0.5);
  animation: turnExpiredPulse 1s ease-in-out infinite alternate;
}

.turn-text {
  font-size: 14px;
  letter-spacing: 0.1em;
}

.turn-timer-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(0, 0, 0, 0.45);
  font-weight: 700;
  min-width: 110px;
  box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.4);
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.turn-timer-display .timer-icon {
  font-size: 16px;
}

.turn-timer-display .timer-value {
  font-size: 20px;
  letter-spacing: 0.08em;
}

.turn-timer-display.timer-warning {
  background: rgba(251, 191, 36, 0.15);
  border-color: rgba(251, 191, 36, 0.6);
  box-shadow: 0 0 18px rgba(251, 191, 36, 0.35);
}

.turn-timer-display.timer-critical {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.75);
  box-shadow: 0 0 22px rgba(239, 68, 68, 0.45);
  animation: timerPulse 0.7s ease-in-out infinite alternate;
}

@keyframes timerPulse {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(-2px);
  }
}

@keyframes turnExpiredPulse {
  from {
    box-shadow: 0 0 16px rgba(239, 68, 68, 0.4);
  }
  to {
    box-shadow: 0 0 32px rgba(239, 68, 68, 0.7);
  }
}

@keyframes gradient-shift {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.arena-title-icon {
  font-size: 48px;
  display: inline-block;
  animation: sword-rotate 2s ease-in-out infinite;
  filter: drop-shadow(0 0 15px rgba(192, 132, 252, 0.8));
}

@keyframes sword-rotate {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  25% {
    transform: rotate(-5deg) scale(1.1);
  }
  75% {
    transform: rotate(5deg) scale(1.1);
  }
}

.arena-title-text {
  position: relative;
  font-weight: 900;
  letter-spacing: 6px;
}

.arena-title-text::before {
  content: "АРЕНА";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, #ef4444 0%, #f97316 50%, #fbbf24 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  z-index: -1;
  filter: blur(8px);
  opacity: 0.7;
  animation: glow-pulse 2s ease-in-out infinite;
}

@keyframes glow-pulse {
  0%, 100% {
    opacity: 0.5;
    transform: scale(1);
  }
  50% {
    opacity: 0.9;
    transform: scale(1.02);
  }
}

.arena-title-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(ellipse at center, rgba(192, 132, 252, 0.3) 0%, rgba(255, 158, 200, 0.2) 40%, transparent 70%);
  border-radius: 50%;
  z-index: 1;
  animation: glow-breathe 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes glow-breathe {
  0%, 100% {
    opacity: 0.6;
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
  }
}

.arena-title-wrapper::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, transparent 0%, rgba(192, 132, 252, 0.5) 20%, rgba(255, 158, 200, 0.8) 50%, rgba(192, 132, 252, 0.5) 80%, transparent 100%);
  z-index: 1;
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.6);
  animation: line-glow 2s ease-in-out infinite;
}

@keyframes line-glow {
  0%, 100% {
    opacity: 0.5;
    width: 80%;
  }
  50% {
    opacity: 1;
    width: 100%;
  }
}

.arena-title-wrapper::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(192, 132, 252, 0.15) 0%, transparent 70%);
  border-radius: 50%;
  z-index: 0;
  animation: pulse-ring 2s ease-out infinite;
}

@keyframes pulse-ring {
  0% {
    transform: translate(-50%, -50%) scale(0.8);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0;
  }
}

.section-container {
  max-width: 600px;
  margin: 0 auto;
}

/* Арена */
.arena-container {
  max-width: 600px;
  margin: 0 auto;
}

.arena-card {
  background: linear-gradient(135deg, var(--chibi-card), rgba(192, 132, 252, 0.2));
  border: 3px solid var(--chibi-border);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.arena-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--chibi-border);
}

.arena-header h3 {
  font-size: 22px;
  color: var(--chibi-text);
}

.arena-level {
  background: var(--chibi-gold);
  color: var(--chibi-bg);
  padding: 8px 14px;
  border-radius: 16px;
  font-weight: bold;
  font-size: 14px;
}

.arena-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.btn-primary,
.btn-secondary {
  border: none;
  border-radius: 16px;
  padding: 16px 24px;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  color: var(--chibi-text);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  border: 2px solid var(--chibi-border);
}

.btn-secondary:active {
  transform: scale(0.98);
}

.btn-large {
  padding: 18px 32px;
  font-size: 18px;
}

.arena-stats {
  display: flex;
  justify-content: space-around;
  padding-top: 16px;
  border-top: 2px solid var(--chibi-border);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-label {
  font-size: 12px;
  color: var(--chibi-text-muted);
  text-transform: uppercase;
}

.stat-value {
  font-size: 22px;
  font-weight: bold;
  color: var(--chibi-gold);
}

.placeholder-text {
  text-align: center;
  color: var(--chibi-text-muted);
  padding: 40px 20px;
  font-size: 16px;
}

.placeholder-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 40px 30px;
  text-align: center;
  margin: 20px auto;
  max-width: 500px;
}

.placeholder-icon {
  font-size: 64px;
  margin-bottom: 20px;
  opacity: 0.7;
}

.placeholder-title {
  font-size: 24px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 16px;
}

/* Магазин */
.shop-content {
  padding: 0 4px;
}

/* Категории магазина */
.shop-categories {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: thin;
  scrollbar-color: var(--chibi-purple) transparent;
}

.shop-categories::-webkit-scrollbar {
  height: 4px;
}

.shop-categories::-webkit-scrollbar-track {
  background: transparent;
}

.shop-categories::-webkit-scrollbar-thumb {
  background: var(--chibi-purple);
  border-radius: 2px;
}

.shop-category {
  flex-shrink: 0;
  padding: 12px 20px;
  background: rgba(45, 27, 78, 0.6);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 80px;
}

.shop-category:hover {
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
  transform: translateY(-2px);
}

.shop-category.active {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.2));
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.3);
}

.shop-category .category-icon {
  font-size: 24px;
  line-height: 1;
}

.shop-category .category-label {
  font-size: 12px;
  white-space: nowrap;
}

/* Баннер магазина */
.shop-banner {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.3), rgba(251, 191, 36, 0.3));
  border: 2px solid var(--chibi-red);
  border-radius: 16px;
  padding: 16px 20px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}

.shop-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.1) 0%, transparent 70%);
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% {
    opacity: 0.5;
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.1);
  }
}

.banner-content {
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  z-index: 1;
}

.banner-icon {
  font-size: 48px;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.banner-text {
  flex: 1;
}

.banner-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 4px;
}

.banner-desc {
  font-size: 14px;
  color: var(--chibi-text-muted);
}

.banner-btn {
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--chibi-red), var(--chibi-orange));
  border: none;
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  white-space: nowrap;
}

.banner-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* Сетка товаров */
.shop-items-grid {
  display: flex;
  flex-direction: column;
  gap: 30px;
  margin-bottom: 20px;
}

.shop-items-group {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.shop-group-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(96, 165, 250, 0.15));
  border: 2px solid rgba(192, 132, 252, 0.3);
  border-radius: 12px;
  margin-bottom: 5px;
}

.group-icon {
  font-size: 24px;
  filter: drop-shadow(0 0 8px rgba(192, 132, 252, 0.6));
}

.group-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.shop-group-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.shop-group-items-compact {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.shop-group-items-sets {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (max-width: 640px) {
  .shop-group-items-compact {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  
  .shop-group-items-sets {
    gap: 12px;
  }
}

/* Карточка товара */
.shop-item-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.2));
  border: 2px solid var(--chibi-border);
  border-radius: 20px;
  padding: 20px;
  position: relative;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

/* Эффект свечения по краям карточки */
.shop-item-card::after {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink), var(--chibi-blue));
  border-radius: 20px;
  opacity: 0;
  z-index: -1;
  transition: opacity 0.4s;
  filter: blur(8px);
}

.shop-item-card:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 32px rgba(192, 132, 252, 0.5), 0 0 40px rgba(192, 132, 252, 0.2);
}

.shop-item-card:hover::after {
  opacity: 0.6;
}

.shop-item-card.special-offer {
  border-color: var(--chibi-gold);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(239, 68, 68, 0.15));
}

.shop-item-card.special-offer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(251, 191, 36, 0.1) 50%, transparent 70%);
  animation: shine 3s infinite;
}

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

.item-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 10px;
  background: var(--chibi-red);
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  color: var(--chibi-text);
  text-transform: uppercase;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.5);
}

.item-badge.special {
  background: linear-gradient(135deg, var(--chibi-gold), var(--chibi-orange));
  color: var(--chibi-bg);
}

/* Изображение товара */
.item-image {
  width: 100%;
  height: 200px;
  border-radius: 16px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  transition: all 0.4s;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.shop-item-card:hover .item-image {
  transform: scale(1.05);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.item-image.common {
  background: linear-gradient(135deg, rgba(156, 163, 175, 0.3), rgba(107, 114, 128, 0.2));
  border: 2px solid #9ca3af;
}

.item-image.rare {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(37, 99, 235, 0.2));
  border: 2px solid #3b82f6;
}

.item-image.epic {
  background: linear-gradient(135deg, rgba(147, 51, 234, 0.3), rgba(126, 34, 206, 0.2));
  border: 2px solid #9333ea;
}

.item-image.legendary {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(245, 158, 11, 0.2));
  border: 2px solid #fbbf24;
}

.item-image.mythic {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.3), rgba(220, 38, 38, 0.2));
  border: 2px solid #ef4444;
}

.item-image.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.4), rgba(239, 68, 68, 0.3));
  border: 2px solid #fbbf24;
  box-shadow: 0 0 20px rgba(251, 191, 36, 0.5);
}

.item-icon {
  font-size: 72px;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.5));
  transition: all 0.4s;
  animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-5px) scale(1.05);
  }
}

.shop-item-card:hover .item-icon {
  transform: scale(1.1) rotate(5deg);
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.6));
}

.item-rarity-badge {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 12px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
}

.item-rarity-badge.common {
  background: rgba(156, 163, 175, 0.8);
  color: #1f2937;
}

.item-rarity-badge.rare {
  background: rgba(59, 130, 246, 0.8);
  color: #ffffff;
}

.item-rarity-badge.epic {
  background: rgba(147, 51, 234, 0.8);
  color: #ffffff;
}

.item-rarity-badge.legendary {
  background: rgba(251, 191, 36, 0.8);
  color: #1f2937;
}

.item-rarity-badge.mythic {
  background: rgba(239, 68, 68, 0.8);
  color: #ffffff;
}

.item-rarity-badge.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.9), rgba(239, 68, 68, 0.9));
  color: #ffffff;
  box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

/* Информация о товаре */
.item-info {
  flex: 1;
  margin-bottom: 12px;
}

.item-name {
  font-size: 20px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 8px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: 0.3px;
}

.item-description {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.6;
  margin-bottom: 12px;
  min-height: 42px; /* Обеспечиваем одинаковую высоту для всех описаний */
}

.item-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.stat-item {
  font-size: 12px;
  color: var(--chibi-text);
  padding: 6px 10px;
  background: linear-gradient(135deg, rgba(74, 44, 107, 0.7), rgba(192, 132, 252, 0.2));
  border-radius: 8px;
  border: 1px solid rgba(192, 132, 252, 0.3);
  font-weight: 600;
  transition: all 0.3s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.stat-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(96, 165, 250, 0.3));
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(192, 132, 252, 0.4);
}

.item-bonus {
  font-size: 13px;
  color: var(--chibi-gold);
  font-weight: 700;
  margin-top: 8px;
  padding: 6px 12px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(245, 158, 11, 0.2));
  border-radius: 8px;
  display: inline-block;
  border: 1px solid rgba(251, 191, 36, 0.5);
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  animation: bonusPulse 2s ease-in-out infinite;
}

@keyframes bonusPulse {
  0%, 100% {
    box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3);
  }
  50% {
    box-shadow: 0 4px 16px rgba(251, 191, 36, 0.6);
  }
}

.item-old-price {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 8px;
  font-size: 14px;
  color: var(--chibi-text-muted);
  text-decoration: line-through;
  opacity: 0.6;
}

/* Футер карточки товара */
.item-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--chibi-border);
}

.item-price {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 20px;
  font-weight: 700;
  color: var(--chibi-text);
}

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

.price-value {
  font-size: 22px;
  color: var(--chibi-gold);
}

.item-buy-btn {
  flex: 1;
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink));
  border: none;
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.3);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Эффект свечения на кнопке */
.item-buy-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.item-buy-btn:hover::before {
  left: 100%;
}

.item-buy-btn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 20px rgba(192, 132, 252, 0.6), 0 0 30px rgba(192, 132, 252, 0.3);
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
}

.item-buy-btn:active {
  transform: translateY(-1px) scale(0.98);
  box-shadow: 0 2px 8px rgba(192, 132, 252, 0.4);
}

.item-buy-btn.special {
  background: linear-gradient(135deg, var(--chibi-gold), var(--chibi-orange));
}

.item-buy-btn.special:hover {
  box-shadow: 0 4px 12px rgba(251, 191, 36, 0.4);
}

/* Футер для наборов - кнопка на всю ширину */
.item-footer-sets {
  justify-content: center;
}

.item-footer-sets .item-buy-btn {
  flex: none;
  width: 100%;
}

/* Кнопка с ценой внутри */
.item-buy-btn-with-price {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
}

.item-buy-btn-with-price .price-icon {
  font-size: 20px;
}

.item-buy-btn-with-price .price-value {
  font-size: 18px;
  color: var(--chibi-text);
  font-weight: 700;
}

.item-buy-btn-with-price.special .price-value {
  color: var(--chibi-bg);
}

/* Кликабельная карточка товара */
.shop-item-clickable {
  cursor: pointer;
  transition: all 0.3s;
}

.shop-item-clickable:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(192, 132, 252, 0.4);
}

.shop-item-clickable .item-buy-btn {
  pointer-events: auto;
}

/* Пустое состояние магазина */
.shop-empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--chibi-text-muted);
}

.shop-empty-state .empty-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.shop-empty-state .empty-text {
  font-size: 18px;
}

.info-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(96, 165, 250, 0.4));
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: var(--chibi-text);
  font-size: 14px;
  font-weight: bold;
  font-style: italic;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s;
  z-index: 10;
  padding: 0;
  line-height: 1;
  box-shadow: 
    0 4px 12px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(192, 132, 252, 0.4);
  backdrop-filter: blur(8px);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.info-btn:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.7), rgba(96, 165, 250, 0.7));
  transform: scale(1.15) rotate(180deg);
  box-shadow: 
    0 6px 20px rgba(0, 0, 0, 0.6),
    0 0 30px rgba(192, 132, 252, 0.6),
    0 0 40px rgba(96, 165, 250, 0.4);
  border-color: rgba(255, 255, 255, 0.5);
}

.arena-info-btn {
  top: 16px;
  right: 16px;
  z-index: 10;
}

.energy-info-btn {
  top: 0;
  right: 0;
}

.resource-item {
  cursor: pointer;
  transition: all 0.2s;
}

.resource-item:hover {
  transform: scale(1.05);
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.4);
}

.modal-small {
  max-width: 400px;
}

/* Почта */
.mail-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.mail-filter-btn {
  padding: 8px 16px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.mail-filter-btn:hover {
  background: rgba(192, 132, 252, 0.2);
  border-color: var(--chibi-purple);
}

.mail-filter-btn.active {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
}

.mail-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mail-item {
  display: flex;
  gap: 12px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}

.mail-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(2px);
}

.mail-item.unread {
  border-left: 4px solid var(--chibi-purple);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.25), rgba(255, 158, 200, 0.15));
}

.mail-icon {
  font-size: 32px;
  flex-shrink: 0;
}

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

.mail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.mail-sender {
  font-weight: bold;
  color: var(--chibi-text);
  font-size: 14px;
}

.mail-time {
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.mail-subject {
  font-weight: bold;
  color: var(--chibi-text);
  font-size: 15px;
  margin-bottom: 4px;
}

.mail-preview {
  font-size: 13px;
  color: var(--chibi-text-muted);
  line-height: 1.4;
  margin-bottom: 8px;
}

.mail-attachments {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.attachment-badge {
  padding: 4px 8px;
  background: rgba(192, 132, 252, 0.2);
  border: 1px solid var(--chibi-border);
  border-radius: 8px;
  font-size: 11px;
  color: var(--chibi-text);
}

.mail-status {
  flex-shrink: 0;
}

.unread-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--chibi-purple);
  box-shadow: 0 0 8px rgba(192, 132, 252, 0.6);
}

.mail-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--chibi-text-muted);
}

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

.empty-text {
  font-size: 16px;
}

/* Друзья */
.friends-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  border-bottom: 2px solid var(--chibi-border);
  padding-bottom: 8px;
}

.friends-tab {
  padding: 10px 16px;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--chibi-text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: -10px;
}

.friends-tab:hover {
  color: var(--chibi-text);
}

.friends-tab.active {
  color: var(--chibi-purple);
  border-bottom-color: var(--chibi-purple);
}

.friends-tab-content {
  min-height: 300px;
}

.friends-search {
  margin-bottom: 16px;
}

.friends-search-input {
  width: 100%;
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 14px;
}

.friends-search-input::placeholder {
  color: var(--chibi-text-muted);
}

.friends-list-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.friend-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  transition: all 0.2s;
}

.friend-card:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(2px);
}

.friend-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 20px;
  color: var(--chibi-bg);
  flex-shrink: 0;
}

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

.friend-name {
  font-weight: bold;
  color: var(--chibi-text);
  font-size: 15px;
  margin-bottom: 4px;
}

.friend-stats {
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.friend-actions {
  display: flex;
  gap: 8px;
}

.friend-action-btn {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.friend-action-btn:hover {
  background: rgba(192, 132, 252, 0.3);
  border-color: var(--chibi-purple);
  transform: scale(1.1);
}

.friend-action-btn.release-disabled,
.friend-request-btn.release-disabled,
.friend-add-btn.release-disabled {
  opacity: 0.55;
  cursor: not-allowed;
  filter: grayscale(0.35);
}

.friend-action-btn.release-disabled:hover,
.friend-request-btn.release-disabled:hover,
.friend-add-btn.release-disabled:hover {
  transform: none;
  box-shadow: none;
}

.friend-request-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.friend-request-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
}

.friend-request-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.friend-request-btn {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.friend-request-btn.accept {
  background: rgba(34, 197, 94, 0.2);
  border-color: #22c55e;
}

.friend-request-btn.accept:hover {
  background: rgba(34, 197, 94, 0.3);
  transform: scale(1.1);
}

.friend-request-btn.decline {
  background: rgba(239, 68, 68, 0.2);
  border-color: var(--chibi-red);
}

.friend-request-btn.decline:hover {
  background: rgba(239, 68, 68, 0.3);
  transform: scale(1.1);
}

.friends-search-full {
  margin-bottom: 20px;
}

.search-results {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
}

.friend-add-btn {
  margin-left: auto;
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
}

.friend-add-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.shop-item-card.release-focus {
  outline: 2px solid var(--chibi-gold);
  outline-offset: 3px;
  box-shadow: 0 0 22px rgba(251, 191, 36, 0.5);
}

/* Аналитика */
.analytics-header {
  margin-bottom: 20px;
  text-align: center;
}

.league-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 20px;
  border: 2px solid var(--chibi-border);
  font-weight: bold;
  font-size: 18px;
}

.league-emoji {
  font-size: 24px;
}

.analytics-chart {
  margin-bottom: 20px;
  padding: 16px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
}

.chart-title {
  font-size: 14px;
  color: var(--chibi-text-muted);
  margin-bottom: 12px;
  text-align: center;
}

.chart-container {
  width: 100%;
  height: 120px;
  overflow: visible;
}

.chart-svg {
  width: 100%;
  height: 100%;
}

.chart-line {
  filter: drop-shadow(0 2px 4px rgba(251, 191, 36, 0.3));
}

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

.analytics-item {
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.analytics-label {
  font-size: 12px;
  color: var(--chibi-text-muted);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.analytics-value {
  font-size: 24px;
  font-weight: bold;
  color: var(--chibi-gold);
  margin-bottom: 4px;
}

.analytics-sub {
  font-size: 11px;
  color: var(--chibi-text-muted);
}

/* Аналитика */
.analytics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.analytics-item {
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.analytics-label {
  font-size: 12px;
  color: var(--chibi-text-muted);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.analytics-value {
  font-size: 24px;
  font-weight: bold;
  color: var(--chibi-gold);
  margin-bottom: 4px;
}

.analytics-sub {
  font-size: 11px;
  color: var(--chibi-text-muted);
}

.extrapass-benefits {
  margin: 12px 0;
  font-size: 14px;
  color: var(--chibi-text);
  line-height: 1.6;
}

.extrapass-benefits div {
  margin: 4px 0;
}

.admin-players-list {
  max-height: 400px;
  overflow-y: auto;
}

.admin-stats-summary {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  text-align: center;
}

.admin-stat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-stat-label {
  font-size: 16px;
  color: var(--chibi-text);
  font-weight: 500;
}

.admin-stat-value {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-gold);
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.admin-stat-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s;
}

.admin-stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 20px rgba(192, 132, 252, 0.4);
  border-color: var(--chibi-purple);
}

.admin-stat-icon {
  font-size: 32px;
  margin-bottom: 8px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.admin-stat-card .admin-stat-label {
  font-size: 14px;
  color: var(--chibi-text-muted);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.admin-stat-card .admin-stat-value {
  font-size: 28px;
  font-weight: bold;
  color: var(--chibi-gold);
}

.admin-player-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  margin-bottom: 8px;
  transition: all 0.2s;
}

.admin-player-item:hover {
  background: rgba(192, 132, 252, 0.2);
  border-color: var(--chibi-purple);
}

.player-info-admin {
  flex: 1;
}

.player-name-admin {
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 4px;
}

.player-stats-admin {
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.player-actions-admin {
  display: flex;
  gap: 8px;
}

.btn-small {
  padding: 6px 12px;
  border-radius: 8px;
  border: 2px solid var(--chibi-border);
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  cursor: pointer;
  font-size: 14px;
}

.btn-small:active {
  transform: scale(0.95);
}

/* Баттлпасс */
.battlepass-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.2));
  border: 3px solid rgba(251, 191, 36, 0.6);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 0 20px rgba(251, 191, 36, 0.4), inset 0 0 15px rgba(251, 191, 36, 0.1);
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1;
}

.battlepass-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 8px;
}

.battlepass-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.battlepass-title {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
  display: flex;
  align-items: center;
  gap: 6px;
}

.battlepass-season {
  font-size: 11px;
  color: var(--chibi-text-muted);
  margin-top: 2px;
  padding-top: 4px;
  border-top: 1px solid rgba(192, 132, 252, 0.2);
}

.battlepass-stars {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-gold);
}

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

.stars-separator {
  color: var(--chibi-text-muted);
  margin: 0 4px;
}

.battlepass-progress {
  margin-top: 8px;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(192, 132, 252, 0.15);
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid var(--chibi-border);
  position: relative;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--chibi-gold), var(--chibi-extrapass));
  border-radius: 8px;
  transition: width 0.5s ease;
  box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

/* Арена */
.arena-main-card {
  background-image: url("/DesignAssets/Images/arena.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 3px solid rgba(251, 191, 36, 0.4);
  border-radius: 24px;
  padding: 32px 24px;
  margin-bottom: 16px;
  text-align: center;
  box-shadow: 
    0 12px 48px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(251, 191, 36, 0.2) inset,
    0 0 60px rgba(192, 132, 252, 0.3);
  backdrop-filter: blur(2px);
  position: relative;
  overflow: hidden;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Темный оверлей для читаемости текста */
.arena-main-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(26, 15, 46, 0.75) 0%,
    rgba(45, 27, 78, 0.65) 50%,
    rgba(26, 15, 46, 0.8) 100%
  );
  z-index: 0;
}

/* Дополнительный градиентный оверлей для глубины */
.arena-main-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(192, 132, 252, 0.15) 0%,
    transparent 70%
  );
  z-index: 1;
  pointer-events: none;
}

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

.arena-shield {
  margin-bottom: 20px;
  position: relative;
  z-index: 2;
  cursor: pointer;
  user-select: none;
}

.shield-icon {
  font-size: 120px;
  filter: 
    drop-shadow(0 8px 24px rgba(192, 132, 252, 0.8))
    drop-shadow(0 0 20px rgba(251, 191, 36, 0.6))
    drop-shadow(0 0 40px rgba(192, 132, 252, 0.4));
  animation: float 3s ease-in-out infinite;
  display: inline-block;
  transition: all 0.3s ease;
  text-shadow: 0 0 30px rgba(251, 191, 36, 0.5);
}

.arena-shield.shield-clicked .shield-icon {
  transform: scale(1.2) rotate(15deg);
  filter: 
    drop-shadow(0 12px 32px rgba(251, 191, 36, 1))
    drop-shadow(0 0 30px rgba(251, 191, 36, 0.8))
    drop-shadow(0 0 60px rgba(192, 132, 252, 0.6));
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.shield-particle {
  position: absolute;
  width: 6px;
  height: 6px;
  background: var(--chibi-gold);
  border-radius: 50%;
  pointer-events: none;
  z-index: 100;
}

.arena-name {
  font-size: 26px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 16px;
  text-shadow: 
    2px 2px 12px rgba(0, 0, 0, 0.9),
    0 0 20px rgba(192, 132, 252, 0.5),
    0 0 40px rgba(251, 191, 36, 0.3);
  position: relative;
  z-index: 2;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.arena-stats-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
  position: relative;
  z-index: 2;
  flex-wrap: wrap;
}

.arena-trophies {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 22px;
  font-weight: bold;
  color: var(--chibi-gold);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(245, 158, 11, 0.15));
  padding: 10px 18px;
  border-radius: 16px;
  border: 2px solid rgba(251, 191, 36, 0.4);
  box-shadow: 
    0 4px 16px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(251, 191, 36, 0.2) inset,
    0 0 30px rgba(251, 191, 36, 0.1);
  text-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.8),
    0 0 15px rgba(251, 191, 36, 0.5);
  backdrop-filter: blur(8px);
  cursor: pointer;
  transition: all 0.3s ease;
}

.arena-trophies:hover {
  transform: scale(1.05);
  border-color: rgba(251, 191, 36, 0.7);
  box-shadow: 
    0 6px 24px rgba(0, 0, 0, 0.5),
    0 0 30px rgba(251, 191, 36, 0.3) inset,
    0 0 40px rgba(251, 191, 36, 0.2);
}

.arena-energy-compact {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 16px;
  font-weight: bold;
  color: var(--chibi-extrapass);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(251, 191, 36, 0.2));
  padding: 10px 16px;
  border-radius: 16px;
  border: 2px solid rgba(245, 158, 11, 0.5);
  white-space: nowrap;
  box-shadow: 
    0 4px 16px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(245, 158, 11, 0.2) inset,
    0 0 30px rgba(245, 158, 11, 0.1);
  text-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.8),
    0 0 15px rgba(245, 158, 11, 0.5);
  backdrop-filter: blur(8px);
  position: relative;
  z-index: 2;
}

.energy-extrapass-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: linear-gradient(135deg, var(--chibi-extrapass), var(--chibi-gold));
  color: var(--chibi-bg);
  border: 2px solid var(--chibi-bg);
  border-radius: 50%;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  margin-left: 2px;
  padding: 0;
  line-height: 1;
  flex-shrink: 0;
}

.energy-extrapass-hint:hover {
  transform: scale(1.1);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.6);
}

.trophies-separator {
  color: var(--chibi-text-muted);
  margin: 0 4px;
}

.energy-icon {
  font-size: 24px;
  filter: 
    drop-shadow(0 2px 8px rgba(245, 158, 11, 0.8))
    drop-shadow(0 0 15px rgba(245, 158, 11, 0.5));
  animation: energyPulse 2s ease-in-out infinite;
}

@keyframes energyPulse {
  0%, 100% { 
    filter: 
      drop-shadow(0 2px 8px rgba(245, 158, 11, 0.8))
      drop-shadow(0 0 15px rgba(245, 158, 11, 0.5));
  }
  50% { 
    filter: 
      drop-shadow(0 2px 12px rgba(245, 158, 11, 1))
      drop-shadow(0 0 25px rgba(245, 158, 11, 0.8));
  }
}

.energy-text {
  display: flex;
  align-items: center;
  gap: 4px;
}

.energy-separator {
  color: var(--chibi-text-muted);
  margin: 0 2px;
}

.trophy-icon {
  font-size: 32px;
  filter: 
    drop-shadow(0 4px 12px rgba(251, 191, 36, 0.8))
    drop-shadow(0 0 20px rgba(251, 191, 36, 0.5));
  animation: trophyGlow 2s ease-in-out infinite;
}

@keyframes trophyGlow {
  0%, 100% { 
    filter: 
      drop-shadow(0 4px 12px rgba(251, 191, 36, 0.8))
      drop-shadow(0 0 20px rgba(251, 191, 36, 0.5));
  }
  50% { 
    filter: 
      drop-shadow(0 4px 16px rgba(251, 191, 36, 1))
      drop-shadow(0 0 30px rgba(251, 191, 36, 0.8));
  }
}

.arena-actions-main {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  position: relative;
  z-index: 2;
  margin-top: 8px;
}

.target-btn {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 3px solid rgba(192, 132, 252, 0.6);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(255, 158, 200, 0.4));
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 
    0 4px 16px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(192, 132, 252, 0.4),
    0 0 40px rgba(192, 132, 252, 0.2);
  backdrop-filter: blur(8px);
  position: relative;
  z-index: 2;
}

.target-btn:hover {
  transform: scale(1.1);
  box-shadow: 
    0 6px 24px rgba(0, 0, 0, 0.6),
    0 0 30px rgba(192, 132, 252, 0.6),
    0 0 60px rgba(192, 132, 252, 0.3);
  border-color: rgba(192, 132, 252, 0.9);
}

.target-btn:active {
  transform: scale(0.95);
}

.target-icon {
  font-size: 32px;
}

.battle-btn {
  min-width: 220px;
  padding: 22px 48px;
  font-size: 24px;
  font-weight: bold;
  letter-spacing: 3px;
  background: linear-gradient(135deg, 
    rgba(255, 158, 200, 0.95) 0%,
    rgba(192, 132, 252, 0.95) 50%,
    rgba(96, 165, 250, 0.95) 100%);
  color: var(--chibi-text);
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 24px;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.6),
    0 0 40px rgba(192, 132, 252, 0.5),
    0 0 60px rgba(255, 158, 200, 0.3),
    inset 0 2px 10px rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  text-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(255, 255, 255, 0.3);
  position: relative;
  z-index: 2;
  backdrop-filter: blur(10px);
}

.battle-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, 
    rgba(255, 255, 255, 0.1) 0%,
    transparent 50%,
    rgba(255, 255, 255, 0.05) 100%);
  border-radius: 24px;
  pointer-events: none;
}

.battle-btn:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 
    0 12px 48px rgba(0, 0, 0, 0.7),
    0 0 60px rgba(192, 132, 252, 0.7),
    0 0 80px rgba(255, 158, 200, 0.5),
    inset 0 2px 10px rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
}

.battle-btn:active {
  transform: translateY(-2px) scale(0.98);
  box-shadow: 
    0 6px 24px rgba(0, 0, 0, 0.6),
    0 0 40px rgba(192, 132, 252, 0.4),
    0 0 60px rgba(255, 158, 200, 0.3);
}

/* Слоты кейсов */
.cases-slots {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  overflow: hidden;
}

/* Хранилище кейсов */
.cases-storage-wrapper {
  margin-top: 20px;
  width: 100%;
  position: relative;
}

/* Накладной бейдж с подсказкой о получении кейсов в боях */
.cases-hint-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: linear-gradient(135deg, 
    rgba(96, 165, 250, 0.95) 0%,
    rgba(135, 206, 250, 0.9) 100%);
  border: 2px solid rgba(96, 165, 250, 0.8);
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  z-index: 10;
  box-shadow: 
    0 4px 16px rgba(96, 165, 250, 0.4),
    0 0 24px rgba(135, 206, 250, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  animation: hintBadgeFloat 3s ease-in-out infinite;
  backdrop-filter: blur(10px);
}

@keyframes hintBadgeFloat {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
    box-shadow: 
      0 4px 16px rgba(96, 165, 250, 0.4),
      0 0 24px rgba(135, 206, 250, 0.3),
      inset 0 1px 0 rgba(255, 255, 255, 0.3);
  }
  50% {
    transform: translateX(-50%) translateY(-3px);
    box-shadow: 
      0 6px 20px rgba(96, 165, 250, 0.5),
      0 0 30px rgba(135, 206, 250, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.4);
  }
}

.cases-hint-badge .hint-icon {
  font-size: 13px;
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.8));
  animation: hintIconRotate 2s ease-in-out infinite;
}

@keyframes hintIconRotate {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  25% {
    transform: rotate(-10deg) scale(1.1);
  }
  75% {
    transform: rotate(10deg) scale(1.1);
  }
}

.cases-hint-badge .hint-text {
  letter-spacing: 0.3px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.cases-storage-card {
  position: relative;
  background: linear-gradient(145deg, 
    rgba(30, 18, 54, 0.98) 0%,
    rgba(45, 27, 78, 0.95) 50%,
    rgba(30, 18, 54, 0.98) 100%);
  border: none;
  border-radius: 22px;
  padding: 20px 24px;
  overflow: hidden;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.7),
    0 0 80px rgba(255, 215, 0, 0.3),
    0 0 120px rgba(192, 132, 252, 0.4);
  backdrop-filter: blur(12px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

.cases-storage-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 
    0 12px 48px rgba(0, 0, 0, 0.8),
    0 0 120px rgba(255, 215, 0, 0.5),
    0 0 160px rgba(192, 132, 252, 0.6);
}

.cases-particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.cases-particles .particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.8), transparent);
  border-radius: 50%;
  animation: particleFloat 8s ease-in-out infinite;
}

.cases-particles .particle-1 {
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.cases-particles .particle-2 {
  top: 60%;
  left: 80%;
  animation-delay: 2s;
}

.cases-particles .particle-3 {
  top: 80%;
  left: 30%;
  animation-delay: 4s;
}

.cases-particles .particle-4 {
  top: 40%;
  left: 70%;
  animation-delay: 1s;
}

.cases-particles .particle-5 {
  top: 10%;
  left: 50%;
  animation-delay: 3s;
}

@keyframes particleFloat {
  0%, 100% { 
    transform: translate(0, 0) scale(1);
    opacity: 0;
  }
  50% { 
    transform: translate(30px, -40px) scale(1.5);
    opacity: 1;
  }
}

.cases-card-pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  border-radius: 22px;
  background: radial-gradient(
    circle,
    rgba(255, 215, 0, 0.15) 0%,
    rgba(192, 132, 252, 0.1) 40%,
    transparent 70%
  );
  animation: cardPulse 3s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

@keyframes cardPulse {
  0%, 100% { 
    opacity: 0.5;
    transform: translate(-50%, -50%) scale(1);
  }
  50% { 
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
  }
}

.cases-card-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  position: relative;
  z-index: 2;
}

.cases-visual {
  flex-shrink: 0;
}

.cases-box-container {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cases-box-outer-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120px;
  height: 120px;
  background: radial-gradient(
    circle,
    rgba(255, 215, 0, 0.3) 0%,
    rgba(192, 132, 252, 0.25) 30%,
    rgba(255, 158, 200, 0.2) 50%,
    transparent 80%
  );
  border-radius: 50%;
  animation: outerGlowPulse 2.5s ease-in-out infinite;
  z-index: 1;
  filter: blur(8px);
}

@keyframes outerGlowPulse {
  0%, 100% { 
    opacity: 0.6;
    transform: translate(-50%, -50%) scale(1);
  }
  50% { 
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.3);
  }
}

.cases-box-inner-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90px;
  height: 90px;
  background: radial-gradient(
    circle,
    rgba(255, 215, 0, 0.5) 0%,
    rgba(192, 132, 252, 0.4) 40%,
    transparent 70%
  );
  border-radius: 50%;
  animation: innerGlowPulse 2s ease-in-out infinite;
  z-index: 2;
  filter: blur(4px);
}

@keyframes innerGlowPulse {
  0%, 100% { 
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(1) rotate(0deg);
  }
  50% { 
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.15) rotate(180deg);
  }
}

.cases-box {
  font-size: 52px;
  filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.6))
          drop-shadow(0 0 40px rgba(192, 132, 252, 0.4))
          drop-shadow(0 8px 16px rgba(0, 0, 0, 0.5));
  animation: boxFloat 3s ease-in-out infinite;
  position: relative;
  z-index: 5;
  transform-origin: center;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
}

@keyframes boxFloat {
  0%, 100% { 
    transform: translateY(0) rotate(-3deg) scale(1);
  }
  25% { 
    transform: translateY(-10px) rotate(3deg) scale(1.08);
  }
  50% { 
    transform: translateY(-15px) rotate(-3deg) scale(1.1);
  }
  75% { 
    transform: translateY(-10px) rotate(3deg) scale(1.08);
  }
}

.cases-box-energy {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100px;
  height: 100px;
  border: 2px solid rgba(255, 215, 0, 0.4);
  border-radius: 50%;
  animation: energyRotate 4s linear infinite;
  z-index: 3;
}

.cases-box-energy::before,
.cases-box-energy::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border: 1px solid rgba(192, 132, 252, 0.3);
  border-radius: 50%;
}

.cases-box-energy::before {
  animation: energyRotate 3s linear infinite reverse;
}

.cases-box-energy::after {
  animation: energyRotate 5s linear infinite;
  width: 120%;
  height: 120%;
  border-color: rgba(255, 158, 200, 0.2);
}

@keyframes energyRotate {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.cases-box-sparkles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 4;
}

.cases-box-sparkles .sparkle {
  position: absolute;
  font-size: 16px;
  opacity: 0;
  animation: sparkleFloat 2.5s ease-in-out infinite;
  filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.8));
  text-shadow: 0 0 12px rgba(255, 215, 0, 1);
}

.cases-box-sparkles .sparkle-1 {
  top: 5%;
  left: 15%;
  animation-delay: 0s;
}

.cases-box-sparkles .sparkle-2 {
  top: 25%;
  right: 10%;
  animation-delay: 0.4s;
}

.cases-box-sparkles .sparkle-3 {
  bottom: 10%;
  left: 20%;
  animation-delay: 0.8s;
}

.cases-box-sparkles .sparkle-4 {
  top: 60%;
  right: 20%;
  animation-delay: 1.2s;
}

.cases-box-sparkles .sparkle-5 {
  bottom: 25%;
  left: 50%;
  animation-delay: 1.6s;
}

.cases-box-sparkles .sparkle-6 {
  top: 40%;
  left: 5%;
  animation-delay: 2s;
}

@keyframes sparkleFloat {
  0%, 100% { 
    opacity: 0;
    transform: translate(0, 0) scale(0.3) rotate(0deg);
  }
  50% { 
    opacity: 1;
    transform: translate(-15px, -30px) scale(1.2) rotate(180deg);
  }
}

.cases-details {
  flex: 1;
  min-width: 0;
}

.cases-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  margin-bottom: 0;
}

.cases-title {
  font-size: 18px;
  font-weight: 700;
  background: linear-gradient(135deg, 
    rgba(255, 215, 0, 1) 0%,
    rgba(192, 132, 252, 1) 50%,
    rgba(255, 158, 200, 1) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.5px;
  text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.cases-badge-wrapper {
  position: relative;
  display: inline-block;
}

.cases-badge-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 150%;
  height: 180%;
  background: radial-gradient(
    circle,
    rgba(255, 215, 0, 0.5) 0%,
    rgba(192, 132, 252, 0.4) 40%,
    rgba(255, 158, 200, 0.3) 60%,
    transparent 80%
  );
  border-radius: 50%;
  animation: badgeGlowPulse 2s ease-in-out infinite;
  z-index: 0;
  filter: blur(8px);
}

@keyframes badgeGlowPulse {
  0%, 100% { 
    opacity: 0.6;
    transform: translate(-50%, -50%) scale(1);
  }
  50% { 
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.2);
  }
}

.cases-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  height: 44px;
  padding: 0 16px;
  background: linear-gradient(135deg, 
    rgb(255, 215, 0) 0%,
    rgb(192, 132, 252) 50%,
    rgb(255, 158, 200) 100%);
  border: 2px solid rgba(255, 215, 0, 0.8);
  border-radius: 16px;
  font-size: 24px;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.9),
               0 2px 6px rgba(0, 0, 0, 0.6);
  box-shadow: 
    0 6px 24px rgba(255, 215, 0, 0.5),
    0 0 32px rgba(192, 132, 252, 0.4),
    inset 0 2px 0 rgba(255, 255, 255, 0.4),
    inset 0 -2px 0 rgba(0, 0, 0, 0.3);
  animation: badgePulse 1.5s ease-in-out infinite;
  z-index: 1;
  letter-spacing: 0.5px;
}

@keyframes badgePulse {
  0%, 100% { 
    transform: scale(1);
    box-shadow: 
      0 4px 16px rgba(255, 215, 0, 0.4),
      0 0 24px rgba(192, 132, 252, 0.3),
      inset 0 2px 0 rgba(255, 255, 255, 0.3),
      inset 0 -2px 0 rgba(0, 0, 0, 0.2);
  }
  50% { 
    transform: scale(1.08);
    box-shadow: 
      0 6px 24px rgba(255, 215, 0, 0.6),
      0 0 36px rgba(192, 132, 252, 0.5),
      inset 0 2px 0 rgba(255, 255, 255, 0.4),
      inset 0 -2px 0 rgba(0, 0, 0, 0.3);
  }
}

.cases-action-btn {
  flex-shrink: 0;
  padding: 12px 22px;
  font-size: 15px;
  font-weight: 700;
  border-radius: 14px;
  background: linear-gradient(135deg, 
    rgba(255, 215, 0, 0.3) 0%,
    rgba(192, 132, 252, 0.35) 50%,
    rgba(255, 158, 200, 0.3) 100%);
  border: 2px solid rgba(255, 215, 0, 0.5);
  color: #fff;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 
    0 4px 16px rgba(255, 215, 0, 0.3),
    0 0 24px rgba(192, 132, 252, 0.25),
    inset 0 2px 0 rgba(255, 255, 255, 0.25),
    inset 0 -2px 0 rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5),
               0 2px 4px rgba(0, 0, 0, 0.3);
}

.cases-action-btn .btn-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.4), transparent);
  border-radius: 50%;
  transition: width 0.4s, height 0.4s;
  z-index: 0;
}

.cases-action-btn:hover .btn-glow {
  width: 200%;
  height: 200%;
}

.cases-action-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    transparent 0%,
    rgba(255, 255, 255, 0.4) 50%,
    transparent 100%);
  transition: left 0.6s;
  z-index: 1;
}

.cases-action-btn:hover::before {
  left: 100%;
}

.cases-action-btn:hover {
  transform: translateY(-3px) scale(1.05);
  background: linear-gradient(135deg, 
    rgba(255, 215, 0, 0.5) 0%,
    rgba(192, 132, 252, 0.55) 50%,
    rgba(255, 158, 200, 0.5) 100%);
  border-color: rgba(255, 215, 0, 0.8);
  box-shadow: 
    0 6px 24px rgba(255, 215, 0, 0.5),
    0 0 40px rgba(192, 132, 252, 0.4),
    inset 0 2px 0 rgba(255, 255, 255, 0.35),
    inset 0 -2px 0 rgba(0, 0, 0, 0.3);
}

.cases-action-btn:active {
  transform: translateY(-1px) scale(1.02);
}

.cases-action-btn .btn-text {
  position: relative;
  z-index: 2;
  letter-spacing: 0.5px;
}

.cases-action-btn .btn-arrow {
  position: relative;
  z-index: 2;
  font-size: 18px;
  font-weight: bold;
  transition: transform 0.3s;
}

.cases-action-btn:hover .btn-arrow {
  transform: translateX(5px);
}

/* Стили для кнопки "В магазин" */
.cases-shop-btn {
  background: linear-gradient(135deg, 
    rgba(96, 165, 250, 0.4) 0%,
    rgba(135, 206, 250, 0.45) 50%,
    rgba(173, 216, 230, 0.4) 100%);
  border: 2px solid rgba(96, 165, 250, 0.6);
  box-shadow: 
    0 4px 16px rgba(96, 165, 250, 0.3),
    0 0 24px rgba(135, 206, 250, 0.25),
    inset 0 2px 0 rgba(255, 255, 255, 0.25),
    inset 0 -2px 0 rgba(0, 0, 0, 0.2);
}

.cases-shop-btn:hover {
  background: linear-gradient(135deg, 
    rgba(96, 165, 250, 0.6) 0%,
    rgba(135, 206, 250, 0.65) 50%,
    rgba(173, 216, 230, 0.6) 100%);
  border-color: rgba(96, 165, 250, 0.9);
  box-shadow: 
    0 6px 24px rgba(96, 165, 250, 0.5),
    0 0 40px rgba(135, 206, 250, 0.4),
    inset 0 2px 0 rgba(255, 255, 255, 0.35),
    inset 0 -2px 0 rgba(0, 0, 0, 0.3);
}

.cases-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 20px;
  text-align: center;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

/* Новый упрощенный виджет кейсов */
.cases-widget {
  margin-top: 16px;
  width: 100%;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(30, 41, 59, 0.9));
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

.cases-widget-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cases-icon {
  font-size: 24px;
  opacity: 0.8;
}

.cases-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cases-info .cases-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--chibi-text);
  margin: 0;
  text-shadow: none;
}

.cases-count {
  font-size: 18px;
  font-weight: bold;
  color: var(--chibi-accent);
}

.cases-widget .cases-action-btn,
.cases-widget .cases-shop-btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cases-widget .cases-action-btn {
  background: linear-gradient(135deg, var(--chibi-gold), var(--chibi-orange));
  color: white;
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3);
}

.cases-widget .cases-action-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(251, 191, 36, 0.4);
}

.cases-widget .cases-shop-btn {
  background: linear-gradient(135deg, var(--chibi-primary), var(--chibi-secondary));
  color: white;
  box-shadow: 0 2px 8px rgba(96, 165, 250, 0.3);
}

.cases-widget .cases-shop-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(96, 165, 250, 0.4);
}

.cases-widget .cases-action-btn:active,
.cases-widget .cases-shop-btn:active {
  transform: translateY(0);
}

.slots-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  width: 100%;
  max-width: 100%;
}

.case-slot {
  aspect-ratio: 1;
  width: 100%;
  max-width: 100%;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.15), rgba(255, 158, 200, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  transition: all 0.3s;
  overflow: hidden;
}

.case-slot::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.case-slot:hover::before {
  opacity: 1;
}

.case-slot:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(192, 132, 252, 0.4);
  border-color: var(--chibi-purple);
}

.case-slot:active {
  transform: translateY(-2px);
}

.case-slot-premium {
  border-color: var(--chibi-extrapass);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(251, 191, 36, 0.15));
}

.case-slot-premium.locked {
  opacity: 0.6;
  cursor: not-allowed;
  filter: grayscale(0.5);
}

.case-slot-premium.locked:hover {
  transform: none;
  border-color: var(--chibi-extrapass);
}

.cases-section {
  background: linear-gradient(135deg, rgba(30, 18, 54, 0.95), rgba(12, 16, 35, 0.9));
  border: 2px solid var(--chibi-border);
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(12px);
}

.cases-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.case-card {
  position: relative;
  border-radius: 18px;
  padding: 18px;
  background: linear-gradient(145deg, rgba(17, 24, 39, 0.9), rgba(45, 27, 78, 0.85));
  border: 2px solid var(--chibi-border);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  overflow: hidden;
}

.case-card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: conic-gradient(from 0deg, rgba(255, 255, 255, 0.08), transparent 35%, rgba(255, 255, 255, 0.08));
  animation: caseCardGlow 6s linear infinite;
  opacity: 0.6;
  z-index: 0;
  pointer-events: none;
}

.case-card > * {
  position: relative;
  z-index: 1;
}

@keyframes caseCardGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.case-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
  border-color: var(--chibi-pink);
}

.case-card::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.case-card-header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.case-card-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.case-tier-chip {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.5px;
  font-weight: 800;
  color: #fff;
  text-transform: uppercase;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.case-card[data-tier="1"] .case-tier-chip {
  background: linear-gradient(135deg, #60a5fa, #38bdf8);
}

.case-card[data-tier="2"] .case-tier-chip {
  background: linear-gradient(135deg, #34d399, #2dd4bf);
}

.case-card[data-tier="3"] .case-tier-chip {
  background: linear-gradient(135deg, #c084fc, #ec4899);
}

.case-card[data-tier="4"] .case-tier-chip {
  background: linear-gradient(135deg, #fb7185, #f97316);
}

.case-card[data-tier="5"] .case-tier-chip {
  background: linear-gradient(135deg, #fbbf24, #f472b6);
  box-shadow: 0 0 24px rgba(251, 191, 36, 0.45);
}

.case-card[data-tier="1"] {
  background: linear-gradient(160deg, rgba(15, 23, 42, 0.95), rgba(30, 64, 175, 0.7));
  border-color: rgba(59, 130, 246, 0.5);
  box-shadow: 0 10px 30px rgba(59, 130, 246, 0.35);
}

.case-card[data-tier="2"] {
  background: linear-gradient(160deg, rgba(8, 47, 35, 0.95), rgba(16, 185, 129, 0.65));
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.35);
}

.case-card[data-tier="3"] {
  background: linear-gradient(160deg, rgba(46, 16, 101, 0.95), rgba(168, 85, 247, 0.65));
  border-color: rgba(168, 85, 247, 0.5);
  box-shadow: 0 10px 30px rgba(168, 85, 247, 0.4);
}

.case-card[data-tier="4"] {
  background: linear-gradient(160deg, rgba(76, 5, 25, 0.95), rgba(249, 115, 22, 0.65));
  border-color: rgba(249, 115, 22, 0.5);
  box-shadow: 0 10px 30px rgba(249, 115, 22, 0.4);
}

.case-card[data-tier="5"] {
  background: linear-gradient(170deg, rgba(87, 26, 0, 0.95), rgba(253, 224, 71, 0.75));
  border-color: rgba(253, 224, 71, 0.6);
  box-shadow: 0 15px 40px rgba(253, 224, 71, 0.5);
}

.case-card-body,
.case-meta {
  color: rgba(255, 255, 255, 0.85);
}

.case-meta-item {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.case-card-body {
  color: var(--chibi-text-muted);
  font-size: 14px;
  line-height: 1.4;
}

.case-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.case-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.case-card-actions {
  margin-top: auto;
  display: flex;
  gap: 10px;
}

.case-card-actions button {
  flex: 1;
  border: none;
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.case-open-action {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  color: var(--chibi-text);
  box-shadow: 0 6px 18px rgba(192, 132, 252, 0.35);
}

.case-open-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(192, 132, 252, 0.45);
}

.case-details-action {
  background: rgba(255, 255, 255, 0.08);
  color: var(--chibi-text-muted);
}

.cases-empty-state {
  margin-top: 24px;
  padding: 32px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 2px dashed var(--chibi-border);
  text-align: center;
  color: var(--chibi-text-muted);
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.35);
}

.case-opening-content {
  max-width: none;
  width: min(1180px, 96vw);
  min-height: 100vh;
  max-height: none;
  background: linear-gradient(140deg, rgba(8, 4, 24, 0.88), rgba(22, 7, 43, 0.95));
  border: none;
  border-radius: 0;
  padding: clamp(24px, 5vw, 60px);
  box-shadow: 0 0 80px rgba(79, 70, 229, 0.35);
  justify-content: center;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.case-opening-content::before,
.case-opening-content::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.35;
  transition: opacity 0.4s ease;
}

.case-opening-content::before {
  background: radial-gradient(circle at 20% 20%, rgba(236, 72, 153, 0.25), transparent 45%),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.2), transparent 50%),
    radial-gradient(circle at 50% 80%, rgba(251, 191, 36, 0.18), transparent 55%);
}

.case-opening-content::after {
  background-image: linear-gradient(120deg, rgba(255, 255, 255, 0.05) 25%, transparent 55%),
    radial-gradient(circle, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 100%, 220px 220px;
  mix-blend-mode: screen;
  opacity: 0.2;
  animation: caseBackdropDrift 28s linear infinite;
}

@keyframes caseBackdropDrift {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-80px, -60px, 0);
  }
}

.case-opening-content[data-case-stage="select"]::before {
  opacity: 0.25;
}

.case-opening-content[data-case-stage="taps"]::before,
.case-opening-content[data-case-stage="taps"]::after {
  opacity: 0.5;
}

.case-opening-content[data-case-stage="rewards"]::before {
  opacity: 0.15;
}

.case-opening-content.reduced-effects::before,
.case-opening-content.reduced-effects::after {
  display: none;
}

.case-opening-content.reduced-effects .case-visual-aurora,
.case-opening-content.reduced-effects .case-orbit,
.case-opening-content.reduced-effects .case-visual-sparks,
.case-opening-content.reduced-effects .case-tap-spark,
.case-opening-content.reduced-effects .case-upgrade-burst {
  display: none !important;
}

.case-opening-content.reduced-effects .case-visual-shell::before,
.case-opening-content.reduced-effects .case-visual-shell::after {
  opacity: 0.25;
  filter: blur(10px);
}

.case-opening-content.reduced-effects .case-visual-core,
.case-opening-content.reduced-effects .case-visual-core::before,
.case-opening-content.reduced-effects .case-visual-core::after {
  animation: none;
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.2);
}

.case-opening-content.reduced-effects .case-progress-track {
  background: rgba(255, 255, 255, 0.08);
}

.case-opening-content.reduced-effects .case-progress-meter {
  box-shadow: none;
  transition: width 0.25s ease;
}

.case-opening-content.reduced-effects .case-progress-meter.is-pulsing {
  box-shadow: none;
}

.case-opening-content.reduced-effects .case-tap-hint {
  transition: none;
}

.case-opening-content.reduced-effects .case-tap-hint.is-changing,
.case-opening-content.reduced-effects .case-tap-hint.hint-enter {
  opacity: 1;
  transform: none;
}

.case-opening-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.case-opening-header h2 {
  font-size: clamp(26px, 3vw, 36px);
  color: #fff;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-shadow: 0 0 20px rgba(236, 72, 153, 0.5);
  font-weight: 800;
}

.case-opening-body {
  display: flex;
  flex-direction: column;
  gap: 30px;
  align-items: center;
  min-height: calc(100vh - 180px);
}

.case-opening-stage {
  display: none;
  opacity: 0;
  visibility: hidden;
  transform: translateZ(0);
  transition: opacity 0.2s ease, visibility 0.2s ease;
  /* Оптимизация для плавных переходов */
  will-change: opacity, visibility;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  /* Изоляция рендеринга для лучшей производительности */
  contain: layout style paint;
}

.case-opening-stage.active {
  display: block;
  opacity: 1;
  visibility: visible;
  transform: translateZ(0);
  will-change: auto;
}

.case-opening-stage .case-display-container {
  max-width: 640px;
  margin: 0 auto;
}

.case-display-container {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: center;
}

.case-opening-content[data-case-stage="select"] .case-progress-track,
.case-opening-content[data-case-stage="rewards"] .case-progress-track {
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
}

.case-opening-content[data-case-stage="taps"] .case-progress-track {
  opacity: 1;
  transform: translateY(0);
}

.case-stage-info {
  font-size: 15px;
  color: #fff;
  line-height: 1.6;
  text-align: center;
  padding: 12px 20px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.04);
}

.case-display {
  width: min(360px, 85vw);
  height: min(360px, 85vw);
  border-radius: 40px;
  border: 3px solid rgba(255, 255, 255, 0.08);
  background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.12), transparent 65%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  box-shadow: inset 0 0 60px rgba(255, 255, 255, 0.08), 0 0 180px rgba(79, 70, 229, 0.45);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
}

.case-visual-shell {
  position: relative;
  width: 76%;
  height: 76%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  --case-accent: #c084fc;
}

.case-visual-shell::before,
.case-visual-shell::after {
  content: "";
  position: absolute;
  inset: -12%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08), transparent 65%);
  filter: blur(20px);
  opacity: 0.6;
  transition: opacity 0.4s ease;
}

.case-visual-shell::after {
  inset: -5%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05), transparent 55%);
  filter: blur(15px);
}

.case-visual-aurora {
  position: absolute;
  inset: -25%;
  border-radius: 50%;
  background: conic-gradient(from 90deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
  filter: blur(10px);
  animation: caseAuroraSpin 16s linear infinite;
  opacity: 0.6;
}

@keyframes caseAuroraSpin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.case-orbit {
  position: absolute;
  inset: -6%;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  animation: caseOrbit 10s linear infinite;
  pointer-events: none;
}

.case-orbit-outer {
  inset: -12%;
  border-color: rgba(255, 255, 255, 0.08);
  animation-duration: 18s;
}

.case-orbit-inner {
  inset: -2%;
  border-color: rgba(255, 255, 255, 0.15);
  animation-direction: reverse;
}

@keyframes caseOrbit {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.case-visual-sparks {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: visible;
}

.case-visual-glyph {
  font-size: clamp(48px, 12vw, 84px);
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
  z-index: 2;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.4));
}

.case-visual-core-glow {
  position: absolute;
  inset: 18%;
  border-radius: 32px;
  box-shadow: 0 0 45px rgba(255, 255, 255, 0.4);
  opacity: 0.65;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.15), transparent 70%);
}

.case-visual-shell.case-tier-surge .case-visual-core {
  animation: caseTierSurge 0.6s ease;
}

@keyframes caseTierSurge {
  0% {
    transform: scale(0.95);
    filter: brightness(0.9);
  }
  60% {
    transform: scale(1.06);
    filter: brightness(1.2);
  }
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
}

.case-tap-spark {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--spark-color, rgba(255, 255, 255, 0.9));
  box-shadow: 0 0 12px var(--spark-color, rgba(255, 255, 255, 0.9));
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.2);
  animation: caseSpark 0.7s ease-out forwards;
}

@keyframes caseSpark {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.2);
  }
  20% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--spark-translate-x, 0px)), calc(-50% + var(--spark-translate-y, 0px))) scale(0);
  }
}

.case-display:hover {
  transform: translateY(-8px) scale(1.03) rotateX(8deg);
  box-shadow: inset 0 0 80px rgba(255, 255, 255, 0.12), 0 0 220px rgba(236, 72, 153, 0.45);
}

.case-display-tapping.case-hit .case-visual-core {
  animation: caseHitImpact 0.35s ease;
}

@keyframes caseHitImpact {
  0% { transform: scale(1) rotate(0deg); filter: brightness(1); }
  40% { transform: scale(1.08) rotate(-2deg); filter: brightness(1.25); }
  100% { transform: scale(1) rotate(0deg); filter: brightness(1); }
}

.case-tap-ripple {
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.5);
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: caseRipple 0.6s ease-out forwards;
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.4);
}

@keyframes caseRipple {
  0% { opacity: 0.8; transform: translate(-50%, -50%) scale(0.2); }
  80% { opacity: 0.2; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(3.2); }
}

.case-visual-core {
  width: 180px;
  height: 180px;
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 72px;
  color: #fff;
  position: relative;
  box-shadow: 0 0 60px rgba(255, 255, 255, 0.3);
  isolation: isolate;
  animation: caseCorePulse 3.2s ease-in-out infinite;
}

.case-visual-core::after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 24px;
  border: 2px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.25);
}

.case-visual-core::before {
  content: "";
  position: absolute;
  inset: -15px;
  border-radius: 36px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08), transparent 60%);
  filter: blur(12px);
  z-index: -1;
}

@keyframes caseCorePulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 50px rgba(255, 255, 255, 0.25); }
  50% { transform: scale(1.08); box-shadow: 0 0 90px rgba(255, 255, 255, 0.4); }
}

.case-visual-shell {
  /* Изоляция рендеринга */
  contain: layout style paint;
  transform: translateZ(0);
  will-change: transform;
}

.case-visual-shell .case-visual-core {
  width: 100%;
  height: 100%;
  border-radius: 30px;
  position: relative;
  overflow: hidden;
  /* Оптимизация для плавных переходов */
  transform: translateZ(0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  /* Изоляция для лучшей производительности */
  contain: layout style paint;
}

.case-visual-core[data-tier="1"] {
  background: linear-gradient(140deg, #3b82f6, #38bdf8, #7dd3fc);
  box-shadow: 0 0 70px rgba(59, 130, 246, 0.45);
}

.case-visual-core[data-tier="2"] {
  background: linear-gradient(140deg, #10b981, #34d399, #2dd4bf);
  box-shadow: 0 0 70px rgba(16, 185, 129, 0.5);
}

.case-visual-core[data-tier="3"] {
  background: linear-gradient(140deg, #a855f7, #d946ef, #ec4899);
  box-shadow: 0 0 90px rgba(168, 85, 247, 0.55);
}

.case-visual-core[data-tier="4"] {
  background: linear-gradient(140deg, #f43f5e, #f97316, #fb923c);
  box-shadow: 0 0 110px rgba(244, 63, 94, 0.6);
}

.case-visual-core[data-tier="5"] {
  background: linear-gradient(150deg, #fcd34d, #f472b6, #a78bfa, #fcd34d);
  box-shadow: 0 0 140px rgba(252, 211, 77, 0.65);
  animation: divineShift 5s linear infinite;
}

@keyframes divineShift {
  0% { filter: hue-rotate(0deg); }
  50% { filter: hue-rotate(45deg); }
  100% { filter: hue-rotate(0deg); }
}

.case-tier-badge {
  padding: 6px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--chibi-text);
  font-weight: 800;
  letter-spacing: 1px;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 0 12px rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
}

.case-tier-badge[data-tier="1"] {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(56, 189, 248, 0.2));
  border-color: rgba(59, 130, 246, 0.5);
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
}

.case-tier-badge[data-tier="2"] {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.3), rgba(52, 211, 153, 0.2));
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.3);
}

.case-tier-badge[data-tier="3"] {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.3), rgba(217, 70, 239, 0.2));
  border-color: rgba(168, 85, 247, 0.5);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.3);
}

.case-tier-badge[data-tier="4"] {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.3), rgba(249, 115, 22, 0.2));
  border-color: rgba(244, 63, 94, 0.5);
  box-shadow: 0 0 20px rgba(244, 63, 94, 0.3);
}

.case-tier-badge[data-tier="5"] {
  background: linear-gradient(135deg, rgba(252, 211, 77, 0.3), rgba(247, 114, 182, 0.2));
  border-color: rgba(252, 211, 77, 0.5);
  box-shadow: 0 0 20px rgba(252, 211, 77, 0.3);
}

.case-tier-badge.tier-upgraded {
  animation: tierUpgradePulse 0.8s ease;
}

@keyframes tierUpgradePulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 20px currentColor;
  }
  50% {
    transform: scale(1.15);
    box-shadow: 0 0 40px currentColor;
  }
}

.case-visual-shell.case-tier-upgraded .case-visual-core {
  animation: caseUpgradeGlow 0.8s ease;
}

@keyframes caseUpgradeGlow {
  0%, 100% {
    filter: brightness(1);
    box-shadow: 0 0 70px currentColor;
  }
  50% {
    filter: brightness(1.4);
    box-shadow: 0 0 120px currentColor;
  }
}

.case-open-btn,
.case-skip-btn {
  width: 100%;
  border: none;
  border-radius: 14px;
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
}

.case-open-btn {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  color: var(--chibi-text);
  box-shadow: 0 10px 30px rgba(192, 132, 252, 0.4);
}

.case-open-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.case-skip-btn {
  background: rgba(255, 255, 255, 0.08);
  color: var(--chibi-text-muted);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.case-display-tapping {
  cursor: pointer;
}

.case-tap-counter {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
  display: flex;
  gap: 6px;
  align-items: center;
}

.case-tap-hint {
  font-size: 15px;
  color: #fff;
  padding: 10px 18px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.case-tap-hint.is-changing {
  opacity: 0;
  transform: translateY(8px);
}

.case-tap-hint.hint-enter {
  animation: caseHintEnter 0.25s ease-out;
}

@keyframes caseHintEnter {
  0% {
    opacity: 0;
    transform: translateY(6px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.case-tap-indicators {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.tap-indicator {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  transition: all 0.2s;
}

.tap-indicator.active {
  border-color: var(--chibi-pink);
  background: var(--chibi-pink);
  box-shadow: 0 0 12px rgba(255, 99, 206, 0.7);
}

.tap-indicator.completed {
  border-color: rgba(16, 185, 129, 0.9);
  background: rgba(16, 185, 129, 0.8);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.6);
}

.tap-indicator.upgraded {
  border-color: rgba(251, 191, 36, 0.95);
  background: rgba(251, 191, 36, 0.9);
  box-shadow: 0 0 14px rgba(251, 191, 36, 0.75);
}

.case-progress-track {
  width: min(360px, 85vw);
  height: 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  position: relative;
  overflow: hidden;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.case-progress-meter {
  --progress-color: linear-gradient(90deg, rgba(236, 72, 153, 0.9), rgba(14, 165, 233, 0.9));
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: var(--progress-color);
  box-shadow: 0 0 12px rgba(236, 72, 153, 0.5);
  transition: width 0.45s cubic-bezier(0.15, 0.75, 0.35, 1), box-shadow 0.3s ease;
}

.case-progress-meter.is-pulsing {
  box-shadow: 0 0 18px rgba(236, 72, 153, 0.8);
}

.case-progress-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18), transparent 65%);
  filter: blur(8px);
  opacity: 0.5;
}

.case-upgrade-notification {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(192, 132, 252, 0.2));
  border: 1px solid rgba(251, 191, 36, 0.4);
  color: var(--chibi-text);
  font-weight: 700;
  text-align: center;
  display: none;
  animation: upgradePop 0.6s ease forwards;
}

.case-upgrade-notification.active {
  display: block;
}

.case-upgrade-burst {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35), transparent 60%);
  animation: caseUpgradeBurst 1s ease-out forwards;
  mix-blend-mode: screen;
}

.case-upgrade-burst[data-tier="4"],
.case-upgrade-burst[data-tier="5"] {
  background: radial-gradient(circle, rgba(251, 191, 36, 0.5), transparent 65%);
}

@keyframes caseUpgradeBurst {
  0% {
    opacity: 0.9;
    transform: scale(0.85);
  }
  80% {
    opacity: 0.4;
  }
  100% {
    opacity: 0;
    transform: scale(1.35);
  }
}

@keyframes upgradePop {
  0% {
    transform: scale(0.8);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.case-rewards-container {
  text-align: center;
}

.case-stage-transition {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.25), transparent 60%);
  animation: rewardsReveal 0.65s ease forwards;
  z-index: 5;
}

.case-stage-transition::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(236, 72, 153, 0.35), transparent 70%);
  filter: blur(20px);
}

.case-stage-transition-flare {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.4), transparent 60%);
  filter: blur(30px);
  animation: rewardsFlare 0.65s ease forwards;
}

@keyframes rewardsReveal {
  0% { opacity: 0; transform: scale(0.9); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: scale(1.1); }
}

@keyframes rewardsFlare {
  0% { opacity: 0.7; transform: translateX(-30%); }
  100% { opacity: 0; transform: translateX(40%); }
}

.case-rewards-title {
  font-size: 24px;
  margin-bottom: 20px;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 0 0 25px rgba(236, 72, 153, 0.5);
}

.case-rewards-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.reward-item {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.03);
}

.reward-item.jackpot {
  border-color: rgba(251, 191, 36, 0.6);
  box-shadow: 0 0 20px rgba(251, 191, 36, 0.3);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.15), rgba(236, 72, 153, 0.15));
}

.reward-icon {
  font-size: 24px;
  width: 40px;
  text-align: center;
}

.reward-content {
  flex: 1;
  text-align: left;
}

.reward-title {
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 4px;
}

.reward-description {
  font-size: 13px;
  color: var(--chibi-text-muted);
}

.rarity-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  border: 1px solid transparent;
}

.rarity-common {
  background: rgba(156, 163, 175, 0.2);
  border-color: rgba(156, 163, 175, 0.4);
  color: #d1d5db;
}

.rarity-rare {
  background: rgba(96, 165, 250, 0.2);
  border-color: rgba(96, 165, 250, 0.4);
  color: #bfdbfe;
}

.rarity-start {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.4);
  color: #bbf7d0;
}

.rarity-superrare {
  background: rgba(14, 165, 233, 0.2);
  border-color: rgba(14, 165, 233, 0.4);
  color: #bae6fd;
}

.rarity-epic {
  background: rgba(192, 132, 252, 0.2);
  border-color: rgba(192, 132, 252, 0.4);
  color: #f3e8ff;
}

.rarity-legendary {
  background: rgba(249, 115, 22, 0.2);
  border-color: rgba(249, 115, 22, 0.4);
  color: #fed7aa;
}

.rarity-mythic {
  background: rgba(236, 72, 153, 0.2);
  border-color: rgba(236, 72, 153, 0.4);
  color: #fbcfe8;
}

.rarity-divine {
  background: rgba(251, 191, 36, 0.2);
  border-color: rgba(251, 191, 36, 0.4);
  color: #fef3c7;
}

.rarity-limited {
  background: rgba(56, 189, 248, 0.2);
  border-color: rgba(56, 189, 248, 0.4);
  color: #bae6fd;
}

.case-close-btn {
  margin-top: 20px;
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(14, 165, 233, 0.2));
  border: 1px solid rgba(99, 102, 241, 0.4);
  color: var(--chibi-text);
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.case-close-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.2);
}

.case-rewards-note {
  font-size: 13px;
  color: var(--chibi-text-muted);
  margin-top: 8px;
}

.premium-lock-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  z-index: 2;
  pointer-events: none;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.premium-extrapass-promo {
  position: absolute;
  top: -8px;
  right: -8px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  pointer-events: none;
}

.promo-badge {
  background: linear-gradient(135deg, var(--chibi-extrapass), var(--chibi-gold));
  color: var(--chibi-bg);
  border: 2px solid var(--chibi-bg);
  border-radius: 8px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.6);
  animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% {
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.6);
  }
  50% {
    box-shadow: 0 2px 16px rgba(245, 158, 11, 0.9);
  }
}

.premium-badge {
  position: absolute;
  top: -10px;
  right: -10px;
  background: linear-gradient(135deg, var(--chibi-extrapass), var(--chibi-gold));
  color: var(--chibi-bg);
  border: 3px solid var(--chibi-bg);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: bold;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.6);
  z-index: 2;
}


.slot-content {
  font-size: 13px;
  color: var(--chibi-text-muted);
  text-align: center;
  font-weight: 500;
  position: relative;
  z-index: 1;
}

/* Модальные окна боя */
.modal-large {
  max-width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.battle-modes {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
}

.battle-mode-item {
  position: relative;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  gap: 16px;
  cursor: pointer;
  transition: all 0.3s;
  align-items: flex-start;
}

.battle-mode-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(4px);
  box-shadow: 0 4px 16px rgba(192, 132, 252, 0.3);
}

.mode-radio {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.mode-checkmark {
  position: absolute;
  top: 20px;
  right: 20px;
  height: 28px;
  width: 28px;
  background: rgba(192, 132, 252, 0.2);
  border: 3px solid var(--chibi-border);
  border-radius: 50%;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mode-radio:checked ~ .mode-checkmark {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.6);
}

.mode-radio:checked ~ .mode-checkmark::after {
  content: "✓";
  color: white;
  font-size: 18px;
  font-weight: bold;
}

.mode-radio:checked ~ .mode-content {
  opacity: 1;
}

.mode-content {
  display: flex;
  gap: 16px;
  flex: 1;
  transition: opacity 0.3s;
}

.mode-icon {
  font-size: 48px;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.mode-info {
  flex: 1;
}

.mode-name {
  font-size: 22px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 8px;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.mode-time {
  font-size: 14px;
  color: var(--chibi-gold);
  margin-bottom: 12px;
  font-weight: 500;
}

.mode-desc {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.6;
}

.deck-selection {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 3px solid var(--chibi-border);
}

.selection-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 16px;
  text-align: center;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.decks-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.deck-item {
  position: relative;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 16px 20px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 16px;
}

.deck-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.3);
}

.deck-radio {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.deck-checkmark {
  height: 24px;
  width: 24px;
  background: rgba(192, 132, 252, 0.2);
  border: 3px solid var(--chibi-border);
  border-radius: 50%;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.deck-radio:checked ~ .deck-checkmark {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 10px rgba(192, 132, 252, 0.5);
}

.deck-radio:checked ~ .deck-checkmark::after {
  content: "✓";
  color: white;
  font-size: 16px;
  font-weight: bold;
}

.deck-name {
  font-size: 18px;
  color: var(--chibi-text);
  font-weight: 500;
  flex: 1;
}

/* Стиль для выбранного режима боя */
.battle-mode-item.selected {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.25));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.5);
}

/* Стиль для неполной колоды */
.deck-item.deck-incomplete {
  opacity: 0.5;
  cursor: not-allowed;
}

.deck-item.deck-incomplete:hover {
  transform: none;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border-color: var(--chibi-border);
  box-shadow: none;
}

.deck-cards-count {
  font-size: 14px;
  color: var(--chibi-text-muted);
  margin-left: 8px;
}

.battle-play-footer {
  margin-top: 24px;
  display: flex;
  justify-content: center;
}

.btn-play-battle {
  width: 100%;
  max-width: 300px;
  font-size: 20px;
  font-weight: bold;
  padding: 16px 32px;
}

.btn-play-battle:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: linear-gradient(135deg, #4a5568, #2d3748);
}

.training-notice {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(245, 158, 11, 0.15));
  border: 3px solid var(--chibi-gold);
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 24px;
  text-align: center;
  font-size: 15px;
  color: var(--chibi-text);
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(251, 191, 36, 0.3);
}

.training-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.training-option {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 20px;
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
}

.training-option:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.25), rgba(255, 158, 200, 0.2));
  border-color: var(--chibi-purple);
  transform: translateY(-4px);
  box-shadow: 0 6px 20px rgba(192, 132, 252, 0.4);
}

.training-option:active {
  transform: translateY(-2px);
}

.training-option.selected {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.25));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.5);
}

.option-icon {
  font-size: 56px;
  margin-bottom: 16px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.option-name {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 12px;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.option-desc {
  font-size: 13px;
  color: var(--chibi-text-muted);
  line-height: 1.5;
}

.friends-mode-selection {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 3px solid var(--chibi-border);
}

.training-modes-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.training-mode-item {
  position: relative;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 16px;
}

.training-mode-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(4px);
  box-shadow: 0 4px 16px rgba(192, 132, 252, 0.3);
}

.training-mode-radio {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.training-mode-checkmark {
  height: 24px;
  width: 24px;
  background: rgba(192, 132, 252, 0.2);
  border: 3px solid var(--chibi-border);
  border-radius: 50%;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.training-mode-radio:checked ~ .training-mode-checkmark {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 10px rgba(192, 132, 252, 0.5);
}

.training-mode-radio:checked ~ .training-mode-checkmark::after {
  content: "✓";
  color: white;
  font-size: 16px;
  font-weight: bold;
}

.training-mode-content {
  display: flex;
  gap: 16px;
  flex: 1;
}

.training-mode-icon {
  font-size: 32px;
  flex-shrink: 0;
}

.training-mode-info {
  flex: 1;
}

.training-mode-name {
  font-size: 18px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 4px;
}

.training-mode-time {
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.friends-selection {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 2px solid var(--chibi-border);
}

.friends-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.friend-item {
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.friend-item:hover {
  background: rgba(192, 132, 252, 0.2);
  border-color: var(--chibi-purple);
}

.bot-difficulty {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 2px solid rgba(192, 132, 252, 0.3);
}

.bot-difficulty .selection-title {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 12px;
  text-align: center;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(192, 132, 252, 0.2);
}

.training-play-footer {
  position: sticky;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(26, 15, 46, 0.98) 20%, rgba(26, 15, 46, 0.98) 100%);
  padding: 16px 20px 20px;
  margin-top: 20px;
  border-top: 3px solid var(--chibi-border);
  z-index: 10;
  backdrop-filter: blur(10px);
}

.btn-play-training {
  width: 100%;
  padding: 18px;
  font-size: 20px;
  font-weight: bold;
  letter-spacing: 2px;
  text-transform: uppercase;
  border-radius: 16px;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-play-training:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-play-training:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(192, 132, 252, 0.6);
}

.difficulty-item {
  position: relative;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.difficulty-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.25), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
  transform: translateX(2px);
  box-shadow: 0 2px 12px rgba(192, 132, 252, 0.3);
}

.difficulty-item:active {
  transform: translateX(1px);
}

.difficulty-radio {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  width: 0;
  height: 0;
}

.difficulty-checkmark {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  background: rgba(192, 132, 252, 0.15);
  border: 2px solid var(--chibi-border);
  border-radius: 50%;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.difficulty-radio:checked ~ .difficulty-checkmark {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 10px rgba(192, 132, 252, 0.5);
}

.difficulty-radio:checked ~ .difficulty-checkmark::after {
  content: "✓";
  color: white;
  font-size: 16px;
  font-weight: bold;
  line-height: 1;
}

.difficulty-radio:checked ~ .difficulty-content {
  color: var(--chibi-text);
}

.difficulty-item:has(.difficulty-radio:checked) {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.2));
  border-color: var(--chibi-purple);
  box-shadow: 0 0 15px rgba(192, 132, 252, 0.4);
}

.difficulty-content {
  flex: 1;
  position: relative;
  z-index: 1;
  padding-right: 0;
}

.battle-play-footer {
  position: sticky;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(26, 15, 46, 0.98) 20%, rgba(26, 15, 46, 0.98) 100%);
  padding: 16px 20px 20px;
  margin-top: 20px;
  border-top: 3px solid var(--chibi-border);
  z-index: 10;
  backdrop-filter: blur(10px);
}

.btn-play-battle {
  width: 100%;
  padding: 18px;
  font-size: 20px;
  font-weight: bold;
  letter-spacing: 2px;
  text-transform: uppercase;
  border-radius: 16px;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-play-battle:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-play-battle:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(192, 132, 252, 0.6);
}

.difficulty-name {
  font-size: 16px;
  font-weight: bold;
  color: var(--chibi-text);
  margin-bottom: 6px;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  line-height: 1.3;
}

.difficulty-desc {
  font-size: 12px;
  color: var(--chibi-text-muted);
  line-height: 1.4;
  line-height: 1.6;
}

/* Нижняя панель навигации */
.bottom-nav {
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: linear-gradient(180deg, rgba(26, 15, 46, 0.95) 0%, rgba(45, 27, 78, 0.95) 100%);
  backdrop-filter: blur(10px);
  border-top: 3px solid var(--chibi-border);
  padding: 10px 0;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
  position: sticky;
  bottom: 0;
  z-index: 100;
  border-radius: 20px 20px 0 0;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  color: var(--chibi-text-muted);
  cursor: pointer;
  padding: 8px 12px;
  transition: all 0.2s;
  border-radius: 12px;
  min-width: 60px;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.nav-item:active {
  transform: scale(0.95);
}

.nav-item.active {
  color: var(--chibi-pink);
  background: rgba(255, 158, 200, 0.2);
}

.nav-item[data-section="arena"].active {
  color: var(--chibi-text);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(255, 158, 200, 0.3));
  box-shadow: 0 0 15px rgba(192, 132, 252, 0.5), inset 0 0 10px rgba(255, 158, 200, 0.2);
  border: 2px solid var(--chibi-purple);
  transform: scale(1.05);
}

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

.nav-label {
  font-size: 11px;
  font-weight: bold;
}

/* Адаптивность */
@media (max-width: 480px) {
  .top-bar {
    padding: 10px 12px;
  }

  .player-avatar {
    width: 48px;
    height: 48px;
    font-size: 18px;
  }

  .player-name {
    font-size: 16px;
  }

  .resource-item {
    padding: 4px 8px;
    font-size: 12px;
  }

  .section-title {
    font-size: 22px;
  }

  .arena-card {
    padding: 16px;
  }

  .nav-icon {
    font-size: 20px;
  }

  .nav-label {
    font-size: 10px;
  }
}

/* Кастомные уведомления */
.game-notification {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10001;
  animation: notificationSlideIn 0.3s ease-out;
  max-width: 90%;
  width: auto;
  min-width: 280px;
}

@keyframes notificationSlideIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.notification-content {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(192, 132, 252, 0.2));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 16px 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(192, 132, 252, 0.4);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
}

.notification-icon {
  font-size: 28px;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.notification-text {
  font-size: 15px;
  color: var(--chibi-text);
  font-weight: 500;
  line-height: 1.4;
  flex: 1;
}

.game-notification.success .notification-content {
  border-color: #10b981;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(16, 185, 129, 0.4);
}

.game-notification.error .notification-content {
  border-color: var(--chibi-red);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(239, 68, 68, 0.4);
}

.game-notification.warning .notification-content {
  border-color: var(--chibi-orange);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(249, 115, 22, 0.4);
}

/* Кастомные модальные окна для alert и confirm */
.game-alert-modal,
.game-confirm-modal {
  z-index: 10002;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: modalFadeIn 0.3s ease-out;
}

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

.game-alert-content,
.game-confirm-content {
  background: linear-gradient(135deg, 
    rgba(45, 27, 78, 0.98) 0%,
    rgba(26, 15, 46, 0.98) 50%,
    rgba(45, 27, 78, 0.98) 100%);
  border: 3px solid var(--chibi-border);
  border-radius: 20px;
  max-width: 400px;
  width: 90%;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.7),
    0 0 40px rgba(192, 132, 252, 0.3);
  backdrop-filter: blur(12px);
  overflow: hidden;
  animation: modalSlideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.game-alert-header,
.game-confirm-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 2px solid rgba(192, 132, 252, 0.2);
  position: relative;
}

.game-alert-icon,
.game-confirm-icon {
  font-size: 32px;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.game-alert-close,
.game-confirm-close {
  background: transparent;
  border: none;
  color: var(--chibi-text-muted);
  font-size: 24px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.2s;
  line-height: 1;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-alert-close:hover,
.game-confirm-close:hover {
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-text);
  transform: scale(1.1);
}

.game-alert-body,
.game-confirm-body {
  padding: 24px;
  text-align: center;
}

.game-alert-message,
.game-confirm-message {
  font-size: 16px;
  color: var(--chibi-text);
  line-height: 1.6;
  font-weight: 500;
}

.game-alert-footer,
.game-confirm-footer {
  padding: 16px 24px;
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  border-top: 2px solid rgba(192, 132, 252, 0.2);
}

.game-alert-btn,
.game-confirm-btn {
  padding: 12px 24px;
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
  min-width: 100px;
}

.game-alert-btn {
  background: linear-gradient(135deg, 
    rgba(192, 132, 252, 0.3) 0%,
    rgba(255, 158, 200, 0.3) 100%);
  color: var(--chibi-text);
  border-color: var(--chibi-purple);
}

.game-alert-btn:hover {
  background: linear-gradient(135deg, 
    rgba(192, 132, 252, 0.5) 0%,
    rgba(255, 158, 200, 0.5) 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.game-alert-btn:active {
  transform: translateY(0);
}

.game-confirm-btn-cancel {
  background: rgba(45, 27, 78, 0.8);
  color: var(--chibi-text);
  border-color: var(--chibi-border);
}

.game-confirm-btn-cancel:hover {
  background: rgba(192, 132, 252, 0.1);
  border-color: var(--chibi-purple);
}

.game-confirm-btn-confirm {
  background: linear-gradient(135deg, 
    rgba(192, 132, 252, 0.4) 0%,
    rgba(255, 158, 200, 0.4) 100%);
  color: var(--chibi-text);
  border-color: var(--chibi-purple);
}

.game-confirm-btn-confirm:hover {
  background: linear-gradient(135deg, 
    rgba(192, 132, 252, 0.6) 0%,
    rgba(255, 158, 200, 0.6) 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.game-confirm-btn-confirm:active {
  transform: translateY(0);
}

/* Индикатор на кнопке почты в меню */
.menu-item {
  position: relative;
}

.menu-item-notification-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 2px 8px rgba(239, 68, 68, 0.6),
    0 0 12px rgba(239, 68, 68, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  z-index: 10;
  animation: notificationPulse 2s ease-in-out infinite;
  line-height: 1;
  letter-spacing: 0;
}

/* Промокоды */
.promocode-input-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.promocode-input {
  width: 100%;
  padding: 14px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: bold;
}

.promocode-input::placeholder {
  color: var(--chibi-text-muted);
  text-transform: none;
  letter-spacing: normal;
  font-weight: normal;
}

.promocode-input:focus {
  outline: none;
  border-color: var(--chibi-purple);
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.4);
}

.promocode-result {
  margin-top: 16px;
  padding: 12px;
  border-radius: 12px;
  text-align: center;
  font-weight: 500;
}

.promocode-result.success {
  background: rgba(16, 185, 129, 0.2);
  border: 2px solid #10b981;
  color: #10b981;
}

.promocode-result.error {
  background: rgba(239, 68, 68, 0.2);
  border: 2px solid var(--chibi-red);
  color: var(--chibi-red);
}

/* Коллекция */
.collection-content {
  padding: 0 12px 20px;
}

.collection-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 24px;
  background: rgba(45, 27, 78, 0.6);
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 6px;
  position: relative;
}

.collection-tab {
  flex: 1;
  padding: 12px 20px;
  background: transparent;
  border: none;
  border-radius: 12px;
  color: var(--chibi-text-muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  z-index: 1;
}

.collection-tab:hover {
  color: var(--chibi-text);
}

.collection-tab.active {
  color: var(--chibi-text);
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.collection-tab-content {
  display: none;
}

.collection-tab-content.active {
  display: block;
}

/* Пресеты колод */
.deck-presets-section {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

.deck-presets-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(192, 132, 252, 0.2);
}

.preset-create-btn {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink));
  border: 2px solid var(--chibi-purple);
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  flex-shrink: 0;
}

.preset-create-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.preset-create-btn:active {
  transform: scale(0.95);
}

.btn-small {
  padding: 6px 12px;
  font-size: 13px;
}

.deck-preset-item {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.85), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 12px 14px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.deck-preset-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.25), rgba(255, 158, 200, 0.2));
  border-color: var(--chibi-purple);
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.3);
}

.deck-preset-item.active {
  border-color: var(--chibi-purple);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.35), rgba(255, 158, 200, 0.25));
  box-shadow: 0 0 16px rgba(192, 132, 252, 0.5), inset 0 0 20px rgba(192, 132, 252, 0.1);
}

.preset-name-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.preset-name-input {
  background: transparent;
  border: none;
  color: var(--chibi-text);
  font-size: 15px;
  font-weight: 600;
  flex: 1;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}

.preset-name-input:read-only {
  cursor: default;
  pointer-events: none;
}

.preset-name-input:not(:read-only) {
  background: rgba(45, 27, 78, 0.6);
  border: 1px solid var(--chibi-purple);
  cursor: text;
}

.preset-rename-btn {
  background: transparent;
  border: none;
  color: var(--chibi-text-muted);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s;
}

.preset-rename-btn:hover {
  color: var(--chibi-purple);
  background: rgba(192, 132, 252, 0.2);
}

.preset-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.preset-select-btn {
  padding: 6px 12px;
  font-size: 13px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink));
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
}

.preset-select-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.preset-delete-btn {
  background: transparent;
  border: none;
  color: var(--chibi-red);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s;
}

.preset-delete-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  transform: scale(1.1);
}


.preset-name-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.preset-name-input {
  background: transparent;
  border: none;
  color: var(--chibi-text);
  font-size: 15px;
  font-weight: 600;
  flex: 1;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}

.preset-name-input:read-only {
  cursor: default;
  pointer-events: none;
}

.preset-name-input:not(:read-only) {
  background: rgba(45, 27, 78, 0.6);
  border: 1px solid var(--chibi-purple);
  cursor: text;
}

.preset-rename-btn {
  background: transparent;
  border: none;
  color: var(--chibi-text-muted);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s;
}

.preset-rename-btn:hover {
  color: var(--chibi-purple);
  background: rgba(192, 132, 252, 0.2);
}

.preset-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.preset-select-btn {
  padding: 6px 12px;
  font-size: 13px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink));
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
}

.preset-select-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.preset-delete-btn {
  background: transparent;
  border: none;
  color: var(--chibi-red);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s;
}

.preset-delete-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  transform: scale(1.1);
}

.deck-preset-btn {
  flex: 1;
  min-width: 80px;
  padding: 10px 14px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  text-align: center;
}

.deck-preset-btn:hover {
  background: rgba(192, 132, 252, 0.2);
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
  transform: translateY(-2px);
}

.deck-preset-btn.active {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

/* Колода */
.deck-section {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.2));
  border: 2px solid var(--chibi-border);
  border-radius: 18px;
  padding: 18px;
  margin-bottom: 24px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.4), inset 0 0 40px rgba(192, 132, 252, 0.1);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  backdrop-filter: blur(10px);
  position: relative;
}

.deck-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--chibi-purple), transparent);
  opacity: 0.6;
}

.deck-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(192, 132, 252, 0.2);
}

.deck-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-text);
  text-shadow: 0 2px 8px rgba(192, 132, 252, 0.3);
  margin: 0 0 6px 0;
  line-height: 1.2;
}

.deck-save-btn {
  padding: 10px 18px;
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border: none;
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
  white-space: nowrap;
  flex-shrink: 0;
}

.deck-save-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(192, 132, 252, 0.6);
}

.deck-save-btn:active {
  transform: translateY(0);
}


.deck-power {
  font-size: 14px;
  color: var(--chibi-gold);
  font-weight: bold;
  margin: 0;
  text-shadow: 0 2px 6px rgba(251, 191, 36, 0.3);
  display: flex;
  align-items: center;
  gap: 6px;
}

.deck-slot.drag-over {
  border-color: var(--chibi-purple);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(255, 158, 200, 0.3));
  transform: scale(1.1);
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.6);
}

.deck-slot.has-card {
  border-style: solid;
  border-width: 3px;
}

/* Цветная окантовка по редкости */
.deck-slot.rarity-start {
  border-color: #7dd3fc;
}

.deck-slot.rarity-common {
  border-color: #9ca3af;
}

.deck-slot.rarity-rare {
  border-color: #3b82f6;
}

.deck-slot.rarity-epic {
  border-color: #9333ea;
}

.deck-slot.rarity-legendary {
  border-color: #fbbf24;
}

.deck-slot.rarity-mythic {
  border-color: #ef4444;
}

.deck-slot.rarity-divine {
  border-color: #fbbf24;
  animation: divine-border-glow 2s ease-in-out infinite;
}

.deck-slot.rarity-limited {
  border-color: #c084fc;
}

@keyframes divine-border-glow {
  0%, 100% {
    border-color: #fbbf24;
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
  }
  50% {
    border-color: #ef4444;
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.8);
  }
}

/* Эффект добавления карты */
@keyframes card-add-pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
}

@keyframes card-add-glow {
  0% {
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
  50% {
    box-shadow: 0 0 30px 15px rgba(192, 132, 252, 0.8);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
}

.deck-slot.card-add-effect {
  animation: card-add-pulse 0.6s ease-out, card-add-glow 1s ease-out;
  z-index: 100;
}

/* Эффекты для разных редкостей */
.deck-slot.card-add-effect.rarity-common {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-common 1s ease-out;
}

.deck-slot.card-add-effect.rarity-rare {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-rare 1s ease-out;
}

.deck-slot.card-add-effect.rarity-epic {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-epic 1s ease-out;
}

.deck-slot.card-add-effect.rarity-legendary {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-legendary 1s ease-out;
}

.deck-slot.card-add-effect.rarity-mythic {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-mythic 1s ease-out;
}

.deck-slot.card-add-effect.rarity-divine {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-divine 1s ease-out;
}

.deck-slot.card-add-effect.rarity-limited {
  animation: card-add-pulse 0.6s ease-out, card-add-glow-limited 1s ease-out;
}

@keyframes card-add-glow-common {
  0% {
    box-shadow: 0 0 0 0 rgba(156, 163, 175, 0);
  }
  50% {
    box-shadow: 0 0 25px 12px rgba(156, 163, 175, 0.7);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(156, 163, 175, 0);
  }
}

@keyframes card-add-glow-rare {
  0% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
  }
  50% {
    box-shadow: 0 0 30px 15px rgba(59, 130, 246, 0.8);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
  }
}

@keyframes card-add-glow-epic {
  0% {
    box-shadow: 0 0 0 0 rgba(147, 51, 234, 0);
  }
  50% {
    box-shadow: 0 0 35px 18px rgba(147, 51, 234, 0.9);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(147, 51, 234, 0);
  }
}

@keyframes card-add-glow-legendary {
  0% {
    box-shadow: 0 0 0 0 rgba(251, 191, 36, 0);
  }
  50% {
    box-shadow: 0 0 40px 20px rgba(251, 191, 36, 0.9);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(251, 191, 36, 0);
  }
}

@keyframes card-add-glow-mythic {
  0% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
  50% {
    box-shadow: 0 0 45px 22px rgba(239, 68, 68, 0.9);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
}

@keyframes card-add-glow-divine {
  0% {
    box-shadow: 0 0 0 0 rgba(251, 191, 36, 0);
  }
  50% {
    box-shadow: 0 0 50px 25px rgba(251, 191, 36, 1), 0 0 30px 15px rgba(239, 68, 68, 0.8);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(251, 191, 36, 0);
  }
}

@keyframes card-add-glow-limited {
  0% {
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
  50% {
    box-shadow: 0 0 50px 25px rgba(192, 132, 252, 1), 0 0 30px 15px rgba(255, 158, 200, 0.8);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(192, 132, 252, 0);
  }
}

.deck-slot-content {
  width: 100%;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  position: relative;
  box-sizing: border-box;
}

.card-in-slot {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  padding: 0;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-radius: 12px 12px 0 0;
}

.slot-empty {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.slot-empty-icon {
  font-size: 48px;
  color: var(--chibi-text-muted);
  opacity: 0.5;
  font-weight: bold;
  transition: all 0.3s;
  line-height: 1;
}

.slot-empty-text {
  font-size: 12px;
  color: var(--chibi-text-muted);
  opacity: 0.7;
  font-weight: 500;
  text-align: center;
}

.card-in-slot {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-radius: 12px;
  padding: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  cursor: pointer;
}

.card-slot-image-container {
  width: 100%;
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(45, 27, 78, 0.3);
  min-height: 0;
}

.card-slot-image-container .card-upgrade-progress-bottom {
  overflow: visible;
}

.card-slot-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-slot-level-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 11px;
  font-weight: bold;
  color: var(--chibi-gold);
  background: rgba(0, 0, 0, 0.75);
  padding: 3px 7px;
  border-radius: 8px;
  z-index: 10;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
  line-height: 1.2;
}

/* Золотой блок уровня для карт максимального уровня в слотах */
.card-slot-level-badge.card-max-level-badge {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.9), rgba(251, 191, 36, 0.7)) !important;
  color: #000000 !important;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.5);
}

.card-slot-footer {
  width: 100%;
  padding: 6px 8px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(26, 15, 46, 0.95));
  backdrop-filter: blur(8px);
  border-radius: 0 0 12px 12px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-top: 1px solid rgba(192, 132, 252, 0.2);
  flex-shrink: 0;
}

/* Золотая подложка для footer карты максимального уровня в слоте */
.card-slot-footer.card-max-level-footer {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(251, 191, 36, 0.15)) !important;
  border-top: 1px solid rgba(251, 191, 36, 0.4) !important;
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3);
}

.card-slot-name {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
  color: var(--chibi-text);
  line-height: 1.3;
}

/* Золотая подложка для имени карты максимального уровня в слоте */
.card-slot-name.card-max-level-name {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(251, 191, 36, 0.15)) !important;
  border: 2px solid #000000 !important;
  border-radius: 6px;
  padding: 4px 6px;
  color: #000000 !important;
  text-shadow: 0 0 4px rgba(251, 191, 36, 0.3);
  font-weight: 700 !important;
  box-shadow: 0 2px 6px rgba(251, 191, 36, 0.3);
}

.card-slot-power {
  font-size: 9px;
  color: var(--chibi-gold);
  text-align: center;
  font-weight: 600;
  line-height: 1.2;
  opacity: 0.9;
}

/* Черный цвет для мощности на золотой подложке максимального уровня */
.card-slot-footer.card-max-level-footer .card-slot-power {
  color: #000000;
  font-weight: 700;
}

.card-upgrade-progress-bottom {
  width: 100%;
  padding: 5px 6px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  box-sizing: border-box;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: block !important;
  visibility: visible !important;
  border-top: 1px solid rgba(192, 132, 252, 0.2);
  overflow: hidden;
}

.card-upgrade-progress-bottom::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: var(--progress, 0%);
  height: 100%;
  background: linear-gradient(90deg, 
    rgba(192, 132, 252, 0.4) 0%,
    rgba(255, 158, 200, 0.4) 50%,
    rgba(192, 132, 252, 0.4) 100%);
  background-size: 200% 100%;
  animation: progress-shimmer 2s linear infinite;
  transition: width 0.3s ease;
  z-index: 0;
}

@keyframes progress-shimmer {
  0% {
    background-position: 0% 0%;
  }
  100% {
    background-position: 200% 0%;
  }
}

.card-upgrade-progress-bottom .progress-visual-indicator {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 3px;
  min-height: 12px;
}

.card-upgrade-progress-bottom .progress-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: calc(var(--progress, 0%) * 0.8);
  max-width: 80%;
  height: 8px;
  background: radial-gradient(ellipse, rgba(192, 132, 252, 0.6) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(4px);
  transition: opacity 0.3s ease, width 0.3s ease;
  pointer-events: none;
}

.card-upgrade-progress-bottom .progress-stars {
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.card-upgrade-progress-bottom .progress-stars .puzzle-piece {
  display: inline-block;
  font-size: 11px;
  line-height: 1;
  transition: opacity 0.3s ease, filter 0.3s ease;
}

.card-upgrade-progress-bottom .progress-stars .puzzle-piece.filled {
  opacity: 1;
  text-shadow: 0 0 4px rgba(251, 191, 36, 0.8);
  filter: drop-shadow(0 0 2px rgba(192, 132, 252, 0.6));
}

.card-upgrade-progress-bottom .progress-stars .puzzle-piece.empty {
  opacity: 0.3;
  filter: grayscale(0.8) brightness(0.5);
}

.card-upgrade-progress-bottom .progress-text {
  font-size: 8px;
  color: var(--chibi-text);
  text-align: center;
  white-space: nowrap;
  line-height: 1.2;
  position: relative;
  z-index: 1;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

/* Ползунок для карт в коллекции */
.card-item-image-container .card-upgrade-progress-bottom {
  width: 100%;
  padding: 5px 6px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  box-sizing: border-box;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: block !important;
  visibility: visible !important;
  border-top: 1px solid rgba(192, 132, 252, 0.2);
  overflow: hidden;
}

.card-item-image-container .card-upgrade-progress-bottom::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: var(--progress, 0%);
  height: 100%;
  background: linear-gradient(90deg, 
    rgba(192, 132, 252, 0.4) 0%,
    rgba(255, 158, 200, 0.4) 50%,
    rgba(192, 132, 252, 0.4) 100%);
  background-size: 200% 100%;
  animation: progress-shimmer 2s linear infinite;
  transition: width 0.3s ease;
  z-index: 0;
}

.card-item-image-container .card-upgrade-progress-bottom .progress-visual-indicator {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 3px;
  min-height: 12px;
}

.card-item-image-container .card-upgrade-progress-bottom .progress-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: calc(var(--progress, 0%) * 0.8);
  max-width: 80%;
  height: 8px;
  background: radial-gradient(ellipse, rgba(192, 132, 252, 0.6) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(4px);
  transition: opacity 0.3s ease, width 0.3s ease;
  pointer-events: none;
}

.card-item-image-container .card-upgrade-progress-bottom .progress-stars {
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.card-item-image-container .card-upgrade-progress-bottom .progress-stars .puzzle-piece {
  display: inline-block;
  font-size: 11px;
  line-height: 1;
  transition: opacity 0.3s ease, filter 0.3s ease;
}

.card-item-image-container .card-upgrade-progress-bottom .progress-stars .puzzle-piece.filled {
  opacity: 1;
  text-shadow: 0 0 4px rgba(251, 191, 36, 0.8);
  filter: drop-shadow(0 0 2px rgba(192, 132, 252, 0.6));
}

.card-item-image-container .card-upgrade-progress-bottom .progress-stars .puzzle-piece.empty {
  opacity: 0.3;
  filter: grayscale(0.8) brightness(0.5);
}

.card-item-image-container .card-upgrade-progress-bottom .progress-text {
  font-size: 8px;
  color: var(--chibi-text);
  text-align: center;
  white-space: nowrap;
  line-height: 1.2;
  position: relative;
  z-index: 1;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.card-slot-rarity-badge {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  text-align: center;
  padding: 2px 8px;
  border-radius: 8px;
  font-weight: bold;
  text-transform: uppercase;
  white-space: nowrap;
  z-index: 10;
}

.card-slot-rarity-badge.common {
  background: rgba(156, 163, 175, 0.9);
  border: 1px solid #9ca3af;
  color: #d1d5db;
}

.card-slot-rarity-badge.rare {
  background: rgba(59, 130, 246, 0.9);
  border: 1px solid #3b82f6;
  color: #93c5fd;
}

.card-slot-rarity-badge.epic {
  background: rgba(147, 51, 234, 0.9);
  border: 1px solid #9333ea;
  color: #c084fc;
}

.card-slot-rarity-badge.legendary {
  background: rgba(251, 191, 36, 0.9);
  border: 1px solid #fbbf24;
  color: #fde047;
}

.card-slot-rarity-badge.mythic {
  background: rgba(239, 68, 68, 0.9);
  border: 1px solid #ef4444;
  color: #fca5a5;
}

.card-slot-rarity-badge.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.9), rgba(239, 68, 68, 0.9));
  border: 2px solid #fbbf24;
  color: #fde047;
}

.card-slot-rarity-badge.limited {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.9), rgba(255, 158, 200, 0.9));
  border: 2px solid #c084fc;
  color: #fbbf24;
}

.card-remove-btn {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  background: var(--chibi-red);
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  color: white;
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.8;
  transition: all 0.2s ease;
  z-index: 15;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  padding: 0;
  margin: 0;
  line-height: 1;
}

.card-remove-btn::before {
  content: "✕";
  line-height: 1;
  margin: 0;
  padding: 0;
}

.card-in-slot:hover .card-remove-btn {
  opacity: 1;
}

.card-remove-btn:hover {
  background: #dc2626;
  transform: scale(1.15);
  box-shadow: 0 3px 8px rgba(239, 68, 68, 0.5);
  opacity: 1;
}

.card-remove-btn:active {
  transform: scale(1.05);
}

.draggable-card {
  cursor: grab;
  transition: all 0.2s;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: none;
}

.draggable-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(192, 132, 252, 0.4);
}

.draggable-card.dragging {
  opacity: 0.5;
  cursor: grabbing;
}

.admin-cards-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.deck-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0;
  margin: 0;
  justify-items: center;
  position: relative;
}

/* Оцентровка последнего ряда из 2 карт - если заполнено 7 или 8 слотов */
.deck-grid.last-row-2 {
  grid-template-columns: 1fr 1fr 1fr;
  justify-content: center;
}

.deck-grid.last-row-2 .deck-slot:nth-child(7),
.deck-grid.last-row-2 .deck-slot:nth-child(8) {
  grid-row: 3;
}

.deck-grid.last-row-2 .deck-slot:nth-child(7) {
  grid-column: 2;
}

.deck-grid.last-row-2 .deck-slot:nth-child(8) {
  grid-column: 2;
  position: relative;
  left: calc(100% + 10px);
}

@media (max-width: 768px) {
  .deck-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  
  .deck-section {
    padding: 12px;
  }
}

.deck-slot {
  aspect-ratio: 2/3;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.15), rgba(255, 158, 200, 0.15));
  border: 3px dashed var(--chibi-border);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
  padding: 0;
  box-sizing: border-box;
  min-height: 0;
  width: 100%;
  max-width: 100%;
}

.deck-slot::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.deck-slot:hover::before {
  opacity: 1;
}

.deck-slot:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 20px rgba(192, 132, 252, 0.5);
  border-style: solid;
}

.deck-slot.card-upgradeable {
  border-color: #10b981;
  border-style: solid;
  border-width: 3px;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
  animation: upgradeable-pulse 2s ease-in-out infinite;
}

.deck-slot.card-upgradeable:hover {
  border-color: #10b981;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.6);
}

.deck-slot.card-max-level {
  border: 3px solid var(--chibi-gold);
  box-shadow: 0 0 25px rgba(251, 191, 36, 0.5), inset 0 0 20px rgba(251, 191, 36, 0.1);
  position: relative;
}

.deck-slot.card-max-level::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -3px;
  right: -3px;
  bottom: -3px;
  background: linear-gradient(45deg, var(--chibi-gold), #fbbf24, #fcd34d, var(--chibi-gold));
  background-size: 200% 200%;
  border-radius: 16px;
  z-index: 0;
  opacity: 0.5;
  animation: max-level-glow 3s ease-in-out infinite;
  pointer-events: none;
}

.deck-slot.card-max-level .card-slot-image-container {
  position: relative;
  z-index: 1;
}

.deck-slot.card-max-level:hover {
  border-color: var(--chibi-gold);
  box-shadow: 0 8px 30px rgba(251, 191, 36, 0.7), inset 0 0 25px rgba(251, 191, 36, 0.15);
}

/* Золотая подложка для имени карты максимального уровня в слоте */
.card-slot-name.card-max-level-name {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(251, 191, 36, 0.15));
  border: 1px solid rgba(251, 191, 36, 0.4);
  border-radius: 6px;
  padding: 4px 6px;
  color: var(--chibi-gold);
  text-shadow: 0 0 6px rgba(251, 191, 36, 0.6);
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(251, 191, 36, 0.3);
}

.deck-slot.filled {
  border-style: solid;
  border-color: var(--chibi-purple);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.25));
}

.deck-slot:hover .slot-empty-icon {
  opacity: 0.8;
  transform: scale(1.1);
  color: var(--chibi-purple);
}

.deck-slot:hover .slot-empty-text {
  opacity: 1;
}

/* Фильтры */
.cards-filters,
.items-filters {
  margin-bottom: 20px;
  padding: 14px 14px;
  background: rgba(45, 27, 78, 0.6);
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1000;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.filter-group-row .filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group-row .filter-group:first-child {
  flex: 2;
  min-width: 300px;
}

.filter-group label {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.rarity-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.rarity-filter {
  padding: 4px 8px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 8px;
  color: var(--chibi-text-muted);
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  white-space: nowrap;
}

.rarity-filter:hover {
  background: rgba(192, 132, 252, 0.2);
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
}

.rarity-filter.active {
  background: linear-gradient(135deg, var(--chibi-pink), var(--chibi-purple));
  border-color: var(--chibi-purple);
  color: var(--chibi-text);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

/* Сетка карт */
.cards-grid,
.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

.empty-state-card-collection {
  grid-column: 1 / -1;
  padding: 24px 20px;
  margin: 16px 0;
}

.empty-state-content {
  display: flex;
  align-items: center;
  gap: 20px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.6), rgba(192, 132, 252, 0.2));
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 24px 20px;
  text-align: left;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

.empty-state-content .empty-icon {
  font-size: 56px;
  opacity: 0.8;
  animation: float 3s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

.empty-state-content .empty-info {
  flex: 1;
}

.empty-state-content .empty-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--chibi-text);
  margin-bottom: 8px;
}

.empty-state-content .empty-text {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.5;
  margin: 0;
}

.card-placeholder,
.item-placeholder {
  aspect-ratio: 2/3;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.15));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.card-placeholder::before,
.item-placeholder::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.card-placeholder:hover::before,
.item-placeholder:hover::before {
  opacity: 1;
}

.card-placeholder:hover,
.item-placeholder:hover {
  transform: translateY(-6px) scale(1.05);
  box-shadow: 0 8px 24px rgba(192, 132, 252, 0.5);
  border-color: var(--chibi-purple);
}

.card-icon,
.item-icon {
  font-size: 64px;
  margin-bottom: 8px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  z-index: 1;
}

.card-name,
.item-name {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
  text-align: center;
  margin-bottom: 6px;
  z-index: 1;
}

.card-rarity,
.item-rarity {
  font-size: 11px;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 1;
}

/* Редкости */
.card-rarity.common,
.item-rarity.common {
  background: rgba(156, 163, 175, 0.3);
  border: 1px solid #9ca3af;
  color: #d1d5db;
}

.card-rarity.rare,
.item-rarity.rare {
  background: rgba(59, 130, 246, 0.3);
  border: 1px solid #3b82f6;
  color: #93c5fd;
}

.card-rarity.epic,
.item-rarity.epic {
  background: rgba(147, 51, 234, 0.3);
  border: 1px solid #9333ea;
  color: #c084fc;
}

.card-rarity.legendary,
.item-rarity.legendary {
  background: rgba(251, 191, 36, 0.3);
  border: 1px solid #fbbf24;
  color: #fde047;
}

.card-rarity.mythic,
.item-rarity.mythic {
  background: rgba(239, 68, 68, 0.3);
  border: 1px solid #ef4444;
  color: #fca5a5;
}

.card-rarity.divine,
.item-rarity.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.4), rgba(239, 68, 68, 0.4));
  border: 2px solid #fbbf24;
  color: #fde047;
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.5);
}

.card-rarity.limited,
.item-rarity.limited {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(255, 158, 200, 0.4));
  border: 2px solid #c084fc;
  color: #fbbf24;
  box-shadow: 0 0 16px rgba(192, 132, 252, 0.6);
  animation: limited-glow 2s ease-in-out infinite;
}

@keyframes limited-glow {
  0%, 100% {
    box-shadow: 0 0 16px rgba(192, 132, 252, 0.6);
  }
  50% {
    box-shadow: 0 0 24px rgba(192, 132, 252, 0.9), 0 0 32px rgba(255, 158, 200, 0.5);
  }
}

/* Стили для админ-панели промокодов */
.admin-promocode-item {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
  transition: all 0.2s;
}

.admin-promocode-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
}

.promocode-code {
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-gold);
  margin-bottom: 8px;
  letter-spacing: 2px;
}

.promocode-details {
  display: flex;
  gap: 16px;
  margin-bottom: 8px;
  font-size: 14px;
  color: var(--chibi-text-muted);
}

.promocode-rewards {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.promocode-rewards span {
  padding: 4px 10px;
  background: rgba(192, 132, 252, 0.2);
  border: 1px solid var(--chibi-border);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
}

.admin-promocode-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
}

.form-input {
  padding: 12px;
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 14px;
  font-family: inherit;
}

.form-input:focus {
  outline: none;
  border-color: var(--chibi-purple);
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.4);
}

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

.reward-input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.reward-input-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
}

.reward-input-group input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

/* Админка карт/предметов */
.admin-cards-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  border-bottom: 2px solid var(--chibi-border);
  padding-bottom: 8px;
}

.admin-tab-btn {
  padding: 10px 16px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  color: var(--chibi-text-muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  margin-bottom: -10px;
}

.admin-tab-btn:hover {
  color: var(--chibi-text);
}

.admin-tab-btn.active {
  color: var(--chibi-purple);
  border-bottom-color: var(--chibi-purple);
}

.admin-tab-content {
  display: none;
}

.admin-tab-content.active {
  display: block;
}

.admin-cards-list,
.admin-items-list {
  max-height: 400px;
  overflow-y: auto;
}

.admin-card-item {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
  transition: all 0.2s;
}

.admin-card-item:hover {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2), rgba(255, 158, 200, 0.15));
  border-color: var(--chibi-purple);
}

.card-item-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-item-name {
  font-size: 18px;
  font-weight: bold;
  color: var(--chibi-text);
}

.card-item-details {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.card-item-rarity {
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: bold;
  text-transform: uppercase;
}

.card-item-rarity.common {
  background: rgba(156, 163, 175, 0.3);
  border: 1px solid #9ca3af;
  color: #d1d5db;
}

.card-item-rarity.rare {
  background: rgba(59, 130, 246, 0.3);
  border: 1px solid #3b82f6;
  color: #93c5fd;
}

.card-item-rarity.epic {
  background: rgba(147, 51, 234, 0.3);
  border: 1px solid #9333ea;
  color: #c084fc;
}

.card-item-rarity.legendary {
  background: rgba(251, 191, 36, 0.3);
  border: 1px solid #fbbf24;
  color: #fde047;
}

.card-item-rarity.mythic {
  background: rgba(239, 68, 68, 0.3);
  border: 1px solid #ef4444;
  color: #fca5a5;
}

.card-item-rarity.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.4), rgba(239, 68, 68, 0.4));
  border: 2px solid #fbbf24;
  color: #fde047;
}

.card-item-rarity.limited {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.4), rgba(255, 158, 200, 0.4));
  border: 2px solid #c084fc;
  color: #fbbf24;
}

.card-item-power {
  font-size: 14px;
  color: var(--chibi-gold);
  font-weight: bold;
}

.card-item-description {
  font-size: 13px;
  color: var(--chibi-text-muted);
  line-height: 1.4;
  margin-top: 4px;
}

/* Коммьюнити */
.community-tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  background: rgba(45, 27, 78, 0.5);
  border-radius: 16px;
  padding: 8px;
  flex-wrap: wrap;
}

.community-tab {
  flex: 1;
  min-width: 100px;
  padding: 14px 20px;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 12px;
  color: var(--chibi-text-muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.community-tab:hover {
  color: var(--chibi-text);
  background: rgba(192, 132, 252, 0.1);
  border-color: rgba(192, 132, 252, 0.3);
}

.community-tab.active {
  color: var(--chibi-text);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.2));
  border-color: var(--chibi-purple);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.2);
}

.community-tab .tab-icon {
  font-size: 24px;
  line-height: 1;
}

.community-tab .tab-label {
  font-size: 13px;
  font-weight: 600;
}

.community-tab-content {
  display: none;
}

.community-tab-content.active {
  display: block;
}

/* Посты коммьюнити */
.community-posts-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.community-post-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.3s;
}

.community-post-card:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-2px);
}

.post-photo {
  width: 100%;
  height: 200px;
  background: rgba(74, 44, 107, 0.5);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  margin-bottom: 16px;
  color: var(--chibi-text-muted);
}

.post-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  font-size: 14px;
  gap: 12px;
}

.post-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.post-author-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.post-author {
  color: var(--chibi-purple);
  font-weight: 600;
  font-size: 15px;
}

.admin-badge {
  display: inline-block;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(239, 68, 68, 0.2));
  border: 1px solid var(--chibi-gold);
  border-radius: 8px;
  color: var(--chibi-gold);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-date {
  color: var(--chibi-text-muted);
  font-size: 12px;
}

.post-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 12px;
}

.post-content {
  font-size: 15px;
  color: var(--chibi-text-muted);
  line-height: 1.6;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.post-content-html {
  white-space: normal;
}

.post-content-html p {
  margin-bottom: 12px;
}

.post-content-html p:last-child {
  margin-bottom: 0;
}

.post-content-html strong,
.post-content-html b {
  font-weight: 700;
  color: var(--chibi-text);
}

.post-content-html em,
.post-content-html i {
  font-style: italic;
}

.post-content-html u {
  text-decoration: underline;
}

.post-content-html a {
  color: var(--chibi-purple);
  text-decoration: none;
  border-bottom: 1px solid var(--chibi-purple);
  transition: color 0.3s;
}

.post-content-html a:hover {
  color: var(--chibi-pink);
  border-bottom-color: var(--chibi-pink);
}

.post-content-html ul,
.post-content-html ol {
  margin: 12px 0;
  padding-left: 24px;
}

.post-content-html li {
  margin-bottom: 6px;
}

.post-content-html h1,
.post-content-html h2,
.post-content-html h3,
.post-content-html h4,
.post-content-html h5,
.post-content-html h6 {
  margin: 16px 0 12px 0;
  color: var(--chibi-text);
  font-weight: 700;
}

.post-content-html h1 { font-size: 24px; }
.post-content-html h2 { font-size: 20px; }
.post-content-html h3 { font-size: 18px; }
.post-content-html h4 { font-size: 16px; }

.post-content-html code {
  background: rgba(74, 44, 107, 0.5);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: monospace;
  font-size: 14px;
}

.post-content-html pre {
  background: rgba(74, 44, 107, 0.5);
  padding: 12px;
  border-radius: 8px;
  overflow-x: auto;
  margin: 12px 0;
}

.post-content-html blockquote {
  border-left: 3px solid var(--chibi-purple);
  padding-left: 16px;
  margin: 12px 0;
  color: var(--chibi-text-muted);
  font-style: italic;
}

.post-delete-btn {
  padding: 6px 10px;
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid var(--chibi-red);
  border-radius: 8px;
  color: var(--chibi-red);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.post-delete-btn:hover {
  background: rgba(239, 68, 68, 0.3);
  transform: scale(1.1);
}

/* Глобальный чат */
/* Заголовок глобального чата */
.global-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  margin-bottom: 16px;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.15) 0%, rgba(96, 165, 250, 0.15) 100%);
  border: 1px solid var(--chibi-border);
  border-radius: 12px;
}

.chat-fullscreen-btn {
  background: var(--chibi-purple);
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  font-size: 18px;
  padding: 6px 12px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.chat-fullscreen-btn:hover {
  background: var(--chibi-blue);
  transform: scale(1.05);
}

/* Полноэкранный режим чата */
#community-section.chat-fullscreen-mode {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  background: var(--chibi-bg);
  overflow: hidden;
}

#community-section.chat-fullscreen-mode .section-container {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 0;
}

#community-section.chat-fullscreen-mode .community-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
}

#community-section.chat-fullscreen-mode #chat-tab {
  display: flex !important;
  flex-direction: column;
  height: 100%;
  padding: 0;
}

#community-section.chat-fullscreen-mode .global-chat-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  min-height: 0;
}

#community-section.chat-fullscreen-mode .chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  min-height: 0;
}

#community-section.chat-fullscreen-mode .chat-input-container {
  flex-shrink: 0;
  margin: 0;
  padding: 16px 20px;
  border-top: 2px solid var(--chibi-border);
  background: rgba(0, 0, 0, 0.2);
}

.chat-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-fullscreen-close-btn {
  background: var(--chibi-red);
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  font-size: 18px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.chat-fullscreen-close-btn:hover {
  background: #dc2626;
  transform: scale(1.1);
}

#community-section.chat-fullscreen-mode .chat-fullscreen-btn {
  display: none;
}

#community-section.chat-fullscreen-mode .chat-fullscreen-close-btn {
  display: flex !important;
}

.global-chat-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.global-chat-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--chibi-text);
}

/* Плашка вступления в Telegram-чат (скрыта) */
.chat-telegram-promo {
  display: none;
}

@keyframes promoGlow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(192, 132, 252, 0.3);
  }
  50% {
    box-shadow: 0 0 30px rgba(192, 132, 252, 0.6), 0 0 40px rgba(96, 165, 250, 0.4);
  }
}

.chat-telegram-promo::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(192, 132, 252, 0.1), transparent);
  animation: promoShine 3s linear infinite;
}

@keyframes promoShine {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
  }
}

.promo-particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: hidden;
}

.promo-particles::before,
.promo-particles::after {
  content: '✨';
  position: absolute;
  font-size: 20px;
  opacity: 0.6;
  animation: particleFloat 4s ease-in-out infinite;
}

.promo-particles::before {
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.promo-particles::after {
  top: 60%;
  right: 15%;
  animation-delay: 2s;
}

@keyframes particleFloat {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
    opacity: 0.6;
  }
  50% {
    transform: translateY(-20px) rotate(180deg);
    opacity: 1;
  }
}

.promo-icon {
  font-size: 48px;
  margin-bottom: 12px;
  animation: promoIconBounce 2s ease-in-out infinite;
  display: inline-block;
}

@keyframes promoIconBounce {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-10px) scale(1.1);
  }
}

.promo-content {
  position: relative;
  z-index: 1;
}

.promo-text {
  margin-bottom: 16px;
}

.promo-text strong {
  display: block;
  font-size: 18px;
  color: var(--chibi-text);
  margin-bottom: 8px;
}

.promo-text p {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.5;
}

.promo-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--chibi-purple) 0%, var(--chibi-blue) 100%);
  border: 2px solid var(--chibi-purple);
  border-radius: 12px;
  color: var(--chibi-text);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.promo-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.promo-link:hover::before {
  left: 100%;
}

.promo-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(192, 132, 252, 0.5);
}

.promo-link-icon {
  font-size: 18px;
  animation: rocketPulse 1.5s ease-in-out infinite;
}

@keyframes rocketPulse {
  0%, 100% {
    transform: scale(1) rotate(0deg);
  }
  50% {
    transform: scale(1.2) rotate(15deg);
  }
}

.promo-link-text {
  font-weight: 700;
}

.promo-link-arrow {
  transition: transform 0.3s;
}

.promo-link:hover .promo-link-arrow {
  transform: translateX(5px);
}

.global-chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 400px);
  min-height: 400px;
  max-height: 600px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  background: rgba(45, 27, 78, 0.3);
  border-radius: 12px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-message {
  background: rgba(74, 44, 107, 0.5);
  border-radius: 12px;
  padding: 12px;
  border-left: 3px solid var(--chibi-purple);
}

.chat-message-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  font-size: 13px;
}

.chat-message-author {
  color: var(--chibi-purple);
  font-weight: 600;
}

.chat-message-time {
  color: var(--chibi-text-muted);
  font-size: 11px;
}

.chat-message-text {
  color: var(--chibi-text);
  font-size: 14px;
  line-height: 1.5;
  word-wrap: break-word;
}

.chat-empty {
  text-align: center;
  color: var(--chibi-text-muted);
  padding: 40px;
  font-size: 16px;
}

.chat-input-container {
  display: flex;
  gap: 12px;
  align-items: center;
}

.chat-input {
  flex: 1;
  padding: 12px 16px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.3s;
}

.chat-input:focus {
  outline: none;
  border-color: var(--chibi-purple);
}

.chat-send-btn {
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--chibi-purple), var(--chibi-pink));
  border: none;
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  white-space: nowrap;
}

.chat-send-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.chat-send-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Гайды */
.guides-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.guide-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  gap: 16px;
  align-items: center;
  transition: all 0.3s;
  cursor: pointer;
}

.guide-card:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-2px);
}

.guide-icon {
  font-size: 48px;
  flex-shrink: 0;
}

.guide-content {
  flex: 1;
}

.guide-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 8px;
}

.guide-description {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.5;
}

/* Видео */
.videos-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.video-card {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.15));
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.3s;
  cursor: pointer;
}

.video-card:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-2px);
}

.video-placeholder {
  width: 100%;
  height: 160px;
  background: rgba(74, 44, 107, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  color: var(--chibi-text-muted);
}

.video-content {
  padding: 16px;
}

.video-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 8px;
}

.video-description {
  font-size: 13px;
  color: var(--chibi-text-muted);
  line-height: 1.4;
}

.community-empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--chibi-text-muted);
}

.community-empty-state .empty-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.community-empty-state .empty-text {
  font-size: 18px;
}

/* Кнопка создания поста для админа */
.admin-post-create-btn-container {
  margin-bottom: 20px;
  display: flex;
  justify-content: flex-end;
}

/* Футер поста с лайками */
.post-footer {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--chibi-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.post-footer .post-author-info {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.post-like-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(74, 44, 107, 0.5);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.post-like-btn:hover:not(:disabled) {
  border-color: var(--chibi-purple);
  transform: translateY(-2px);
}

.post-like-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.post-like-btn.liked {
  border-color: var(--chibi-red);
  background: rgba(239, 68, 68, 0.2);
}

.post-like-btn.liked .like-icon {
  animation: heartBeat 0.5s ease-in-out;
}

@keyframes heartBeat {
  0%, 100% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.2);
  }
  50% {
    transform: scale(1);
  }
  75% {
    transform: scale(1.1);
  }
}

.like-icon {
  font-size: 18px;
  transition: transform 0.2s;
}

.like-count {
  font-size: 14px;
  color: var(--chibi-text-muted);
}

.post-like-btn.liked .like-count {
  color: var(--chibi-red);
}

/* Анимация лайка */
.post-like-btn.like-animating {
  transform: scale(1.1);
  transition: transform 0.2s ease-out;
}

.post-like-btn.like-animating .like-icon {
  animation: likePulse 0.6s ease-out;
}

@keyframes likePulse {
  0% {
    transform: scale(1) rotate(0deg);
  }
  25% {
    transform: scale(1.3) rotate(-10deg);
  }
  50% {
    transform: scale(1.1) rotate(10deg);
  }
  75% {
    transform: scale(1.2) rotate(-5deg);
  }
  100% {
    transform: scale(1) rotate(0deg);
  }
}

/* Частицы лайка */
.like-particle {
  box-shadow: 0 0 10px rgba(255, 107, 157, 0.8);
}

/* Улучшенное отображение постов */
.community-post {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.9) 0%, rgba(26, 15, 46, 0.9) 100%);
  border: 2px solid var(--chibi-border);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 16px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.community-post:hover {
  border-color: var(--chibi-purple);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(192, 132, 252, 0.2);
}

.post-header {
  margin-bottom: 16px;
}

.post-author-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.post-author-avatar-wrapper {
  position: relative;
  flex-shrink: 0;
}

.post-author-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--chibi-purple) 0%, var(--chibi-blue) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  color: var(--chibi-text);
  box-shadow: 0 2px 6px rgba(192, 132, 252, 0.3);
  overflow: hidden;
  border: 2px solid var(--chibi-border);
  position: relative;
}

.post-author-avatar .avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.post-author-avatar .avatar-initial {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.post-author-avatar.admin-avatar {
  border: 2px solid var(--chibi-gold);
  box-shadow: 0 2px 10px rgba(251, 191, 36, 0.4);
}

.admin-crown {
  position: absolute;
  top: -6px;
  right: -6px;
  font-size: 16px;
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.8));
  z-index: 3;
  background: var(--chibi-bg);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--chibi-gold);
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.5);
}

.post-author-details {
  flex: 1;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.post-author-name {
  font-weight: 600;
  font-size: 12px;
  color: var(--chibi-text);
  display: flex;
  align-items: center;
  gap: 4px;
  line-height: 1.2;
  white-space: nowrap;
}

.admin-badge-text {
  font-size: 9px;
  padding: 1px 4px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(245, 158, 11, 0.2));
  border: 1px solid var(--chibi-gold);
  border-radius: 4px;
  color: var(--chibi-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.post-time {
  font-size: 10px;
  color: var(--chibi-text-muted);
  line-height: 1.2;
  white-space: nowrap;
}

.post-body {
  margin-bottom: 16px;
}

.post-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--chibi-text);
  margin-bottom: 12px;
  line-height: 1.4;
}

.post-content {
  font-size: 15px;
  color: var(--chibi-text-muted);
  line-height: 1.6;
  margin-bottom: 12px;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.post-photo {
  width: 100%;
  max-height: 300px;
  border-radius: 12px;
  background: rgba(45, 27, 78, 0.5);
  padding: 20px;
  text-align: center;
  margin-bottom: 12px;
  border: 2px dashed var(--chibi-border);
}

.post-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--chibi-border);
}

.post-delete-btn {
  background: rgba(239, 68, 68, 0.2);
  border: 2px solid var(--chibi-red);
  border-radius: 8px;
  padding: 8px 12px;
  color: var(--chibi-red);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s;
}

.post-delete-btn:hover {
  background: rgba(239, 68, 68, 0.3);
  transform: scale(1.05);
}

/* Улучшенный чат */
.chat-messages {
  max-height: 400px;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-message {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.6) 0%, rgba(26, 15, 46, 0.6) 100%);
  border: 1px solid var(--chibi-border);
  border-radius: 12px;
  padding: 12px 16px;
  transition: all 0.3s ease;
  animation: messageSlideIn 0.3s ease-out;
}

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

.chat-message.own-message {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2) 0%, rgba(96, 165, 250, 0.2) 100%);
  border-color: var(--chibi-purple);
  margin-left: auto;
  max-width: 80%;
}

.message-header {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}

.message-author-avatar-wrapper {
  position: relative;
  flex-shrink: 0;
}

.message-author-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--chibi-purple) 0%, var(--chibi-blue) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: var(--chibi-text);
  border: 2px solid var(--chibi-border);
  overflow: hidden;
  position: relative;
}

.message-author-avatar .avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.message-author-avatar .avatar-initial {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.message-author-avatar.admin-avatar {
  border: 2px solid var(--chibi-gold);
  box-shadow: 0 2px 6px rgba(251, 191, 36, 0.4);
}

.admin-crown-small {
  position: absolute;
  top: -5px;
  right: -5px;
  font-size: 13px;
  filter: drop-shadow(0 0 4px rgba(251, 191, 36, 0.8));
  z-index: 3;
  background: var(--chibi-bg);
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--chibi-gold);
  box-shadow: 0 2px 6px rgba(251, 191, 36, 0.5);
}

.message-author-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.message-author-name {
  font-weight: 600;
  font-size: 14px;
  color: var(--chibi-text);
  display: flex;
  align-items: center;
  gap: 6px;
}

.admin-badge-text-small {
  font-size: 10px;
  padding: 1px 6px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(245, 158, 11, 0.2));
  border: 1px solid var(--chibi-gold);
  border-radius: 6px;
  color: var(--chibi-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.message-time {
  font-size: 11px;
  color: var(--chibi-text-muted);
}

.message-text {
  font-size: 14px;
  color: var(--chibi-text);
  line-height: 1.5;
  word-wrap: break-word;
  white-space: pre-wrap;
}

.chat-input-container {
  display: flex;
  gap: 8px;
  padding: 12px;
  background: rgba(26, 15, 46, 0.8);
  border-top: 2px solid var(--chibi-border);
}

.chat-input {
  flex: 1;
  padding: 12px 16px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 14px;
  font-family: inherit;
  transition: border-color 0.3s;
}

.chat-input:focus {
  outline: none;
  border-color: var(--chibi-purple);
}

.chat-send-btn {
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--chibi-purple) 0%, var(--chibi-blue) 100%);
  border: none;
  border-radius: 12px;
  color: var(--chibi-text);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s;
}

.chat-send-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.4);
}

.chat-send-btn:active {
  transform: translateY(0);
}

/* Форма создания поста */
.post-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 15px;
  font-weight: 600;
  color: var(--chibi-text);
}

.form-input,
.form-textarea {
  padding: 12px 16px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.3s;
  resize: vertical;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--chibi-purple);
}

.form-textarea {
  min-height: 150px;
  line-height: 1.6;
}

.form-char-count {
  font-size: 12px;
  color: var(--chibi-text-muted);
  text-align: right;
}

.form-hint {
  font-size: 12px;
  color: var(--chibi-text-muted);
  font-style: italic;
}

.form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 8px;
}

.form-actions .btn-secondary,
.form-actions .btn-primary {
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 600;
}

/* Стили для страницы ожидания платежа */
.payment-status {
  margin-top: 20px;
  padding: 20px;
  border-radius: 12px;
  text-align: center;
}

.payment-status.success {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.2) 0%, rgba(34, 197, 94, 0.1) 100%);
  border: 2px solid rgba(34, 197, 94, 0.5);
}

.payment-status.error {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.2) 0%, rgba(239, 68, 68, 0.1) 100%);
  border: 2px solid rgba(239, 68, 68, 0.5);
}

.payment-status-icon {
  font-size: 48px;
  margin-bottom: 10px;
}

.payment-status-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--chibi-text);
}

.purchase-rewards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.purchase-reward-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
}

.purchase-reward-item .reward-icon {
  font-size: 24px;
}

.purchase-reward-item .reward-amount {
  font-size: 16px;
  font-weight: 600;
  color: var(--chibi-text);
}

/* Стили для всплывающего окна успешной покупки */
.purchase-success-modal {
  z-index: 10000;
  backdrop-filter: blur(10px);
}

.purchase-success-content {
  max-width: 450px;
  background: linear-gradient(135deg, #2d1b4e 0%, #1a0f2e 100%);
  border: 3px solid var(--chibi-gold);
  border-radius: 20px;
  padding: 0;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(251, 191, 36, 0.3);
  transform: scale(0.8) translateY(50px);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.purchase-success-content-show {
  transform: scale(1) translateY(0);
  opacity: 1;
}

.purchase-success-header {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2) 0%, rgba(245, 158, 11, 0.1) 100%);
  padding: 30px 20px;
  text-align: center;
  border-bottom: 2px solid rgba(251, 191, 36, 0.3);
}

.purchase-success-icon {
  font-size: 80px;
  margin-bottom: 15px;
  animation: purchaseSuccessIcon 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: inline-block;
}

@keyframes purchaseSuccessIcon {
  0% {
    transform: scale(0) rotate(-180deg);
    opacity: 0;
  }
  60% {
    transform: scale(1.2) rotate(10deg);
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.purchase-success-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--chibi-gold);
  margin: 0;
  text-shadow: 0 0 20px rgba(251, 191, 36, 0.5);
  animation: purchaseSuccessTitle 0.5s ease-out 0.2s both;
}

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

.purchase-success-body {
  padding: 30px 20px;
}

.purchase-success-message {
  font-size: 18px;
  color: var(--chibi-text);
  margin-bottom: 25px;
  text-align: center;
  animation: purchaseSuccessMessage 0.5s ease-out 0.3s both;
}

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

.purchase-rewards-container {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 20px;
}

.purchase-reward-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 20px;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.15) 0%, rgba(96, 165, 250, 0.15) 100%);
  border: 2px solid rgba(192, 132, 252, 0.3);
  border-radius: 15px;
  opacity: 0;
  transform: scale(0.8) translateX(-30px);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.purchase-reward-item.reward-animate {
  opacity: 1;
  transform: scale(1) translateX(0);
}

.reward-icon-large {
  font-size: 48px;
  animation: rewardIconPulse 1s ease-in-out infinite;
  filter: drop-shadow(0 0 10px rgba(251, 191, 36, 0.6));
}

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

.reward-amount-large {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.reward-amount-value {
  font-size: 36px;
  font-weight: 700;
  color: var(--chibi-gold);
  text-shadow: 0 0 15px rgba(251, 191, 36, 0.6);
  line-height: 1;
}

.reward-amount-label {
  font-size: 14px;
  color: var(--chibi-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Специальные стили для ExtraPass */
.purchase-reward-extrapass {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.25) 0%, rgba(245, 158, 11, 0.15) 100%) !important;
  border: 3px solid rgba(251, 191, 36, 0.6) !important;
  box-shadow: 0 0 30px rgba(251, 191, 36, 0.4), inset 0 0 20px rgba(251, 191, 36, 0.1);
  position: relative;
  overflow: hidden;
}

.purchase-reward-extrapass::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.3) 0%, transparent 70%);
  animation: extrapassGlow 3s ease-in-out infinite;
}

@keyframes extrapassGlow {
  0%, 100% {
    transform: rotate(0deg) scale(1);
    opacity: 0.5;
  }
  50% {
    transform: rotate(180deg) scale(1.2);
    opacity: 0.8;
  }
}

.reward-icon-extrapass {
  font-size: 64px !important;
  filter: drop-shadow(0 0 20px rgba(251, 191, 36, 0.8)) !important;
  animation: extrapassIconPulse 1.5s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

@keyframes extrapassIconPulse {
  0%, 100% {
    transform: scale(1) rotate(0deg);
  }
  25% {
    transform: scale(1.15) rotate(-5deg);
  }
  50% {
    transform: scale(1.2) rotate(0deg);
  }
  75% {
    transform: scale(1.15) rotate(5deg);
  }
}

.reward-extrapass-title {
  font-size: 28px;
  font-weight: 800;
  color: var(--chibi-gold);
  text-shadow: 0 0 20px rgba(251, 191, 36, 0.8), 0 2px 4px rgba(0, 0, 0, 0.5);
  letter-spacing: 2px;
  text-transform: uppercase;
  position: relative;
  z-index: 1;
}

.reward-extrapass-subtitle {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  margin-top: 5px;
  position: relative;
  z-index: 1;
}

/* Стили для кейсов в наградах */
.purchase-reward-case {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(139, 92, 246, 0.15) 100%) !important;
  border: 2px solid rgba(168, 85, 247, 0.5) !important;
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.3);
}

.purchase-success-footer {
  padding: 20px;
  border-top: 2px solid rgba(251, 191, 36, 0.2);
  background: rgba(0, 0, 0, 0.2);
}

.purchase-success-btn {
  width: 100%;
  padding: 16px;
  font-size: 18px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--chibi-gold) 0%, var(--chibi-extrapass) 100%);
  border: none;
  border-radius: 12px;
  color: var(--chibi-bg);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(251, 191, 36, 0.4);
  animation: purchaseSuccessBtn 0.5s ease-out 0.5s both;
}

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

.purchase-success-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(251, 191, 36, 0.6);
}

.purchase-success-btn:active {
  transform: translateY(0);
}

/* Анимация значений ресурсов в профиле */
.resource-animate {
  animation: resourceBounce 0.6s ease-out;
}

@keyframes resourceBounce {
  0%, 100% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.3);
    color: var(--chibi-gold);
  }
  50% {
    transform: scale(1.1);
  }
  75% {
    transform: scale(1.2);
  }
}

/* Стили для карт с изображениями */
.card-item {
  display: flex;
  flex-direction: column;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.8), rgba(192, 132, 252, 0.1));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: none;
  padding: 0;
  cursor: pointer;
  transition: all 0.3s;
  overflow: hidden;
  position: relative;
  aspect-ratio: 2/3;
  min-height: 0;
  z-index: 1;
}

.card-item:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 10px 24px rgba(192, 132, 252, 0.5);
  border-color: var(--chibi-purple);
  border-width: 3px;
}

.card-item.card-upgradeable {
  border-color: #10b981;
  border-width: 3px;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
  animation: upgradeable-pulse 2s ease-in-out infinite;
}

@keyframes upgradeable-pulse {
  0%, 100% {
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
  }
  50% {
    box-shadow: 0 0 30px rgba(16, 185, 129, 0.6);
  }
}

.card-item.card-upgradeable:hover {
  border-color: #10b981;
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.6);
}

.card-item.card-max-level {
  border: 3px solid var(--chibi-gold);
  box-shadow: 0 0 25px rgba(251, 191, 36, 0.5), inset 0 0 20px rgba(251, 191, 36, 0.1);
  position: relative;
}

.card-item.card-max-level .card-item-image-container {
  position: relative;
  z-index: 1;
}

.card-item.card-max-level::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -3px;
  right: -3px;
  bottom: -3px;
  background: linear-gradient(45deg, var(--chibi-gold), #fbbf24, #fcd34d, var(--chibi-gold));
  background-size: 200% 200%;
  border-radius: 12px;
  z-index: 0;
  opacity: 0.5;
  animation: max-level-glow 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes max-level-glow {
  0%, 100% {
    opacity: 0.8;
    background-position: 0% 50%;
    box-shadow: 0 0 25px rgba(251, 191, 36, 0.5);
  }
  50% {
    opacity: 1;
    background-position: 100% 50%;
    box-shadow: 0 0 35px rgba(251, 191, 36, 0.7);
  }
}

.card-item.card-max-level:hover {
  border-color: var(--chibi-gold);
  box-shadow: 0 10px 35px rgba(251, 191, 36, 0.7), inset 0 0 25px rgba(251, 191, 36, 0.15);
}

/* Золотая подложка для карты максимального уровня вне слотов */
.card-item-info.card-max-level-info {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(251, 191, 36, 0.15)) !important;
  border: 2px solid #000000 !important;
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3);
  position: relative;
  z-index: 1;
}

.card-item-info.card-max-level-info .card-power {
  color: #000000 !important;
  font-weight: 700;
}

.card-item-info.card-max-level-info .card-name.card-max-level-name {
  color: #000000 !important;
  text-shadow: 0 0 4px rgba(251, 191, 36, 0.3);
  font-weight: 700 !important;
}

.card-item-image-container {
  width: 100%;
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(45, 27, 78, 0.3);
  min-height: 0;
}

.card-item-image-container .card-upgrade-progress-bottom {
  overflow: visible;
}

.card-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-item-level-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 11px;
  font-weight: bold;
  color: var(--chibi-gold);
  background: rgba(0, 0, 0, 0.8);
  padding: 3px 8px;
  border-radius: 8px;
  z-index: 10;
}

/* Золотой блок уровня для карт максимального уровня */
.card-item-level-badge.card-max-level-badge {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.9), rgba(251, 191, 36, 0.7)) !important;
  color: #000000 !important;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(251, 191, 36, 0.5);
}

.card-item-info {
  padding: 8px;
  background: rgba(45, 27, 78, 0.9);
  width: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.card-item-info .card-name {
  font-size: 12px;
  font-weight: bold;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-item-info .card-power {
  font-size: 11px;
  color: var(--chibi-gold);
  text-align: center;
  font-weight: bold;
}

/* Суб-меню для карты в слоте */
.card-slot-menu {
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.3));
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  min-width: 140px;
}

.card-menu-btn {
  padding: 10px 16px;
  background: rgba(192, 132, 252, 0.2);
  border: 2px solid var(--chibi-purple);
  border-radius: 8px;
  color: var(--chibi-text);
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
}

.card-menu-btn:hover {
  background: rgba(192, 132, 252, 0.4);
  transform: translateX(4px);
}

/* Детальный просмотр карты */
.card-detail-modal {
  z-index: 10000;
}

.card-detail-content {
  max-width: 90vw;
  max-height: 90vh;
  width: 400px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(192, 132, 252, 0.2));
  border: 3px solid var(--chibi-border);
  border-radius: 20px;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
}

.card-detail-image-container {
  width: 100%;
  height: 400px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(26, 15, 46, 0.8);
}

.card-detail-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.card-detail-level-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 16px;
  font-weight: bold;
  color: var(--chibi-gold);
  background: rgba(0, 0, 0, 0.8);
  padding: 8px 16px;
  border-radius: 12px;
  z-index: 10;
  border: 2px solid var(--chibi-gold);
}

.card-detail-info {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  max-height: calc(90vh - 400px);
}

.card-detail-name {
  font-size: 28px;
  font-weight: bold;
  color: var(--chibi-text);
  text-align: center;
  margin: 0;
}

.card-detail-rarity {
  text-align: center;
  font-size: 14px;
  font-weight: bold;
  padding: 6px 16px;
  border-radius: 8px;
  text-transform: uppercase;
}

.card-detail-rarity.start {
  background: rgba(125, 211, 252, 0.3);
  color: #7dd3fc;
  border: 1px solid #7dd3fc;
}

.card-detail-rarity.common {
  background: rgba(156, 163, 175, 0.3);
  color: #9ca3af;
  border: 1px solid #9ca3af;
}

.card-detail-rarity.rare {
  background: rgba(59, 130, 246, 0.3);
  color: #93c5fd;
  border: 1px solid #3b82f6;
}

.card-detail-rarity.epic {
  background: rgba(147, 51, 234, 0.3);
  color: #c084fc;
  border: 1px solid #9333ea;
}

.card-detail-rarity.legendary {
  background: rgba(251, 191, 36, 0.3);
  color: #fde047;
  border: 1px solid #fbbf24;
}

.card-detail-rarity.mythic {
  background: rgba(239, 68, 68, 0.3);
  color: #fca5a5;
  border: 1px solid #ef4444;
}

.card-detail-rarity.divine {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(239, 68, 68, 0.3));
  color: #fde047;
  border: 2px solid #fbbf24;
}

.card-detail-rarity.limited {
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.3));
  color: #fbbf24;
  border: 2px solid #c084fc;
}

.card-detail-description {
  font-size: 15px;
  color: var(--chibi-text-muted);
  line-height: 1.6;
  text-align: center;
  margin: 0;
}

.card-detail-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.card-detail-stat {
  background: rgba(192, 132, 252, 0.1);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  padding: 12px;
  text-align: center;
}

.card-detail-stat-full {
  grid-column: 1 / -1;
}

.stat-label {
  font-size: 13px;
  color: var(--chibi-text-muted);
  margin-bottom: 4px;
}

.stat-value {
  font-size: 24px;
  font-weight: bold;
  color: var(--chibi-gold);
}

.stat-value.ready {
  color: #10b981;
  text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

.stat-next {
  font-size: 14px;
  color: var(--chibi-purple);
  margin-top: 4px;
}

.card-detail-upgrade-progress {
  width: 100%;
}

.card-detail-upgrade-progress .progress-bar {
  width: 100%;
  height: 12px;
  background: rgba(45, 27, 78, 0.8);
  border-radius: 6px;
  overflow: hidden;
  border: 2px solid var(--chibi-border);
}

.card-detail-upgrade-progress .progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--chibi-purple), var(--chibi-pink));
  border-radius: 4px;
  transition: width 0.3s ease;
}

.card-upgrade-btn {
  width: 100%;
  padding: 14px;
  font-size: 16px;
  font-weight: bold;
  margin-top: 8px;
}

.card-upgrade-requirements {
  margin-top: 12px;
  padding: 12px;
  background: rgba(239, 68, 68, 0.1);
  border: 2px solid rgba(239, 68, 68, 0.3);
  border-radius: 8px;
}

.requirement-not-met {
  font-size: 13px;
  color: #fca5a5;
  margin-bottom: 6px;
  padding: 6px;
  background: rgba(239, 68, 68, 0.1);
  border-radius: 6px;
  text-align: center;
}

.requirement-not-met:last-child {
  margin-bottom: 0;
}

/* Стили для разных редкостей в детальном просмотре */
.card-detail-content.rarity-start {
  border-color: #7dd3fc;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(125, 211, 252, 0.15));
}

.card-detail-content.rarity-start .card-detail-image-container {
  border-bottom: 3px solid #7dd3fc;
  background: linear-gradient(180deg, rgba(125, 211, 252, 0.1), rgba(26, 15, 46, 0.8));
}

.card-detail-content.rarity-common {
  border-color: #9ca3af;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(156, 163, 175, 0.1));
}

.card-detail-content.rarity-common .card-detail-image-container {
  border-bottom: 3px solid #9ca3af;
}

.card-detail-content.rarity-rare {
  border-color: #3b82f6;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(59, 130, 246, 0.15));
}

.card-detail-content.rarity-rare .card-detail-image-container {
  border-bottom: 3px solid #3b82f6;
}

.card-detail-content.rarity-epic {
  border-color: #9333ea;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(147, 51, 234, 0.2));
}

.card-detail-content.rarity-epic .card-detail-image-container {
  border-bottom: 3px solid #9333ea;
}

.card-detail-content.rarity-legendary {
  border-color: #fbbf24;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(251, 191, 36, 0.2));
  box-shadow: 0 0 30px rgba(251, 191, 36, 0.5);
}

.card-detail-content.rarity-legendary .card-detail-image-container {
  border-bottom: 3px solid #fbbf24;
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.1), rgba(26, 15, 46, 0.8));
}

.card-detail-content.rarity-mythic {
  border-color: #ef4444;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.98), rgba(239, 68, 68, 0.2));
  box-shadow: 0 0 30px rgba(239, 68, 68, 0.5);
}

.card-detail-content.rarity-mythic .card-detail-image-container {
  border-bottom: 3px solid #ef4444;
  background: linear-gradient(180deg, rgba(239, 68, 68, 0.1), rgba(26, 15, 46, 0.8));
}

.card-detail-content.rarity-divine {
  border-color: #fbbf24;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(239, 68, 68, 0.2), rgba(192, 132, 252, 0.2));
  box-shadow: 0 0 40px rgba(251, 191, 36, 0.7), 0 0 60px rgba(239, 68, 68, 0.5);
  animation: divine-glow-pulse 3s ease-in-out infinite;
}

.card-detail-content.rarity-divine .card-detail-image-container {
  border-bottom: 3px solid #fbbf24;
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.2), rgba(239, 68, 68, 0.2), rgba(26, 15, 46, 0.8));
  position: relative;
  overflow: visible;
}

.card-detail-content.rarity-limited {
  border-color: #c084fc;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.25), rgba(255, 158, 200, 0.25));
  box-shadow: 0 0 35px rgba(192, 132, 252, 0.6);
}

.card-detail-content.rarity-limited .card-detail-image-container {
  border-bottom: 3px solid #c084fc;
  background: linear-gradient(180deg, rgba(192, 132, 252, 0.2), rgba(26, 15, 46, 0.8));
}

/* Декорации для редкости */
.card-detail-rarity-decoration {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  opacity: 0.3;
  z-index: 1;
}

.card-detail-rarity-decoration.rarity-legendary {
  background: radial-gradient(circle at center, rgba(251, 191, 36, 0.3), transparent 70%);
}

.card-detail-rarity-decoration.rarity-mythic {
  background: radial-gradient(circle at center, rgba(239, 68, 68, 0.3), transparent 70%);
}

.card-detail-rarity-decoration.rarity-divine {
  background: radial-gradient(circle at center, rgba(251, 191, 36, 0.4), rgba(239, 68, 68, 0.3), transparent 70%);
  animation: divine-decoration-pulse 4s ease-in-out infinite;
}

.card-detail-rarity-decoration.rarity-limited {
  background: radial-gradient(circle at center, rgba(192, 132, 252, 0.3), rgba(255, 158, 200, 0.2), transparent 70%);
}

/* Спецэффекты для божественных карт */
.divine-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.6), rgba(239, 68, 68, 0.4), transparent 70%);
  border-radius: 50%;
  animation: divine-glow-rotate 8s linear infinite;
  pointer-events: none;
  z-index: 1;
}

.divine-particles {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}

.divine-particles .particle {
  position: absolute;
  font-size: 24px;
  animation: divine-particle-float 4s ease-in-out infinite;
  opacity: 0.8;
}

.divine-particles .particle:nth-child(1) {
  top: 15%;
  left: 10%;
  animation-delay: 0s;
}

.divine-particles .particle:nth-child(2) {
  top: 30%;
  right: 15%;
  animation-delay: 0.7s;
}

.divine-particles .particle:nth-child(3) {
  bottom: 35%;
  left: 20%;
  animation-delay: 1.4s;
}

.divine-particles .particle:nth-child(4) {
  bottom: 20%;
  right: 25%;
  animation-delay: 2.1s;
}

.divine-particles .particle:nth-child(5) {
  top: 50%;
  left: 8%;
  animation-delay: 2.8s;
}

.divine-particles .particle:nth-child(6) {
  top: 65%;
  right: 12%;
  animation-delay: 3.5s;
}

@keyframes divine-glow-pulse {
  0%, 100% {
    box-shadow: 0 0 40px rgba(251, 191, 36, 0.7), 0 0 60px rgba(239, 68, 68, 0.5);
  }
  50% {
    box-shadow: 0 0 60px rgba(251, 191, 36, 1), 0 0 80px rgba(239, 68, 68, 0.8);
  }
}

@keyframes divine-glow-rotate {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

@keyframes divine-decoration-pulse {
  0%, 100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.6;
  }
}

@keyframes divine-particle-float {
  0%, 100% {
    transform: translateY(0) scale(1);
    opacity: 0.7;
  }
  50% {
    transform: translateY(-20px) scale(1.2);
    opacity: 1;
  }
}

/* Стили для сортировки */
.filters-header {
  margin-bottom: 0;
  padding-bottom: 0;
  margin-top: 0;
  padding-top: 0;
}

.filters-main {
  display: flex;
  gap: 8px;
  align-items: center;
}

/* Кастомный выпадающий список сортировки */
.custom-sort-select-wrapper {
  position: relative;
  flex: 1;
  z-index: 100002;
}

.custom-sort-select {
  width: 100%;
  padding: 8px 12px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.custom-sort-select:hover {
  border-color: var(--chibi-purple);
  background: rgba(192, 132, 252, 0.1);
}

.custom-sort-select .sort-select-text {
  flex: 1;
  text-align: left;
}

.custom-sort-select .sort-select-arrow {
  font-size: 10px;
  opacity: 0.7;
  transition: transform 0.3s;
}

.custom-sort-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: rgba(45, 27, 78, 0.98);
  border: 2px solid var(--chibi-border);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  z-index: 999999;
  overflow: hidden;
  backdrop-filter: blur(10px);
  isolation: isolate;
}

.sort-option {
  padding: 10px 12px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  border-bottom: 1px solid rgba(192, 132, 252, 0.1);
}

.sort-option:last-child {
  border-bottom: none;
}

.sort-option:hover {
  background: rgba(192, 132, 252, 0.2);
  color: var(--chibi-purple);
}

.sort-option:active {
  background: rgba(192, 132, 252, 0.3);
}

/* Кнопка направления сортировки */
.sort-direction-btn {
  padding: 8px 12px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
  min-width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sort-direction-btn:hover {
  border-color: var(--chibi-purple);
  background: rgba(192, 132, 252, 0.1);
  transform: scale(1.05);
}

.sort-select.compact {
  flex: 1;
  padding: 8px 12px;
  background: rgba(45, 27, 78, 0.8);
  border: 2px solid var(--chibi-border);
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
  min-width: 0;
}

.sort-select.compact:hover {
  border-color: var(--chibi-purple);
  background: rgba(192, 132, 252, 0.1);
}

.sort-select.compact:focus {
  outline: none;
  border-color: var(--chibi-purple);
  box-shadow: 0 0 0 3px rgba(192, 132, 252, 0.3);
}

.sort-select.compact option {
  background: rgba(45, 27, 78, 0.95);
  color: var(--chibi-text);
  padding: 10px;
}

.filter-toggle-btn {
  padding: 8px 16px;
  background: rgba(192, 132, 252, 0.2);
  border: 2px solid var(--chibi-border);
  border-radius: 10px;
  color: var(--chibi-text);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.filter-toggle-btn:hover {
  background: rgba(192, 132, 252, 0.35);
  border-color: var(--chibi-purple);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(192, 132, 252, 0.3);
}

.rarity-filters-collapsible {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(192, 132, 252, 0.2);
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    max-height: 0;
  }
  to {
    opacity: 1;
    max-height: 200px;
  }
}

.rarity-filters-collapsible .rarity-filters {
  gap: 6px;
}

/* UI создания поста */
.create-post-modal {
  z-index: 10000;
}

.create-post-content {
  max-width: 600px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95) 0%, rgba(26, 15, 46, 0.95) 100%);
  border: 3px solid var(--chibi-purple);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(192, 132, 252, 0.3);
}

.create-post-body {
  padding: 24px;
}

.create-post-body .form-group {
  margin-bottom: 20px;
}

.create-post-body .form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--chibi-text);
  font-size: 14px;
}

.create-post-body .form-input,
.create-post-body .form-textarea {
  width: 100%;
  box-sizing: border-box;
}

.create-post-body .form-char-count {
  text-align: right;
  margin-top: 4px;
  font-size: 12px;
  color: var(--chibi-text-muted);
}

.create-post-body .form-hint {
  margin-top: 4px;
  font-size: 12px;
  color: var(--chibi-text-muted);
  font-style: italic;
}

.create-post-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 20px 24px;
  border-top: 2px solid var(--chibi-border);
  background: rgba(0, 0, 0, 0.2);
}

.create-post-footer .btn-primary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-weight: 700;
}

.create-post-footer .btn-icon {
  font-size: 18px;
}

/* Полноэкранный чат */
.chat-fullscreen-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10000;
  backdrop-filter: blur(10px);
}

.chat-fullscreen-modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-fullscreen-content {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  background: linear-gradient(135deg, var(--chibi-bg) 0%, var(--chibi-card) 100%);
  border: none;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  padding: 0;
}

.chat-fullscreen-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 2px solid var(--chibi-border);
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.2) 0%, rgba(96, 165, 250, 0.2) 100%);
}

.chat-fullscreen-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-text);
}

.chat-fullscreen-close {
  background: var(--chibi-red);
  border: none;
  border-radius: 8px;
  color: var(--chibi-text);
  font-size: 20px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.chat-fullscreen-close:hover {
  background: #dc2626;
  transform: scale(1.1);
}

.chat-fullscreen-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-fullscreen-input-container {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  border-top: 2px solid var(--chibi-border);
  background: rgba(0, 0, 0, 0.2);
}

.chat-fullscreen-input {
  flex: 1;
  padding: 12px 16px;
  background: var(--chibi-card);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 16px;
  font-family: inherit;
}

.chat-fullscreen-input:focus {
  outline: none;
  border-color: var(--chibi-purple);
  box-shadow: 0 0 0 3px rgba(192, 132, 252, 0.2);
}

.chat-fullscreen-send-btn {
  padding: 12px 24px;
  background: var(--chibi-purple);
  border: 2px solid var(--chibi-border);
  border-radius: 12px;
  color: var(--chibi-text);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.chat-fullscreen-send-btn:hover:not(:disabled) {
  background: var(--chibi-blue);
  transform: translateY(-2px);
}

.chat-fullscreen-send-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Путь славы - в стиле Clash Royale (компактный и детализированный) */
.glory-path-container {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.glory-path-header {
  margin-bottom: 20px;
  padding: 18px;
  background: linear-gradient(135deg, 
    rgba(26, 15, 46, 0.95) 0%,
    rgba(45, 27, 78, 0.95) 50%,
    rgba(26, 15, 46, 0.95) 100%);
  border-radius: 18px;
  border: 2px solid var(--chibi-border);
  box-shadow: 
    0 6px 24px rgba(0, 0, 0, 0.6),
    inset 0 0 40px rgba(192, 132, 252, 0.1);
  position: relative;
  overflow: hidden;
}

.glory-path-header::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(192, 132, 252, 0.1) 0%, transparent 70%);
  animation: headerRotate 20s linear infinite;
}

@keyframes headerRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.glory-path-current-league {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 16px;
  position: relative;
  z-index: 1;
}

.league-emoji-large {
  font-size: 56px;
  filter: drop-shadow(0 4px 16px rgba(251, 191, 36, 0.8));
  animation: leagueGlow 3s ease-in-out infinite;
  position: relative;
}

.league-emoji-large::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  animation: leagueAura 3s ease-in-out infinite;
}

@keyframes leagueAura {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 0.8;
  }
}

@keyframes leagueGlow {
  0%, 100% {
    filter: drop-shadow(0 4px 16px rgba(251, 191, 36, 0.8));
  }
  50% {
    filter: drop-shadow(0 4px 24px rgba(251, 191, 36, 1));
  }
}

.league-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.league-name-large {
  font-size: 26px;
  font-weight: bold;
  color: var(--chibi-text);
  text-shadow: 
    2px 2px 8px rgba(0, 0, 0, 0.9),
    0 0 20px rgba(192, 132, 252, 0.5);
  letter-spacing: 1px;
}

.league-trophies {
  font-size: 20px;
  color: var(--chibi-gold);
  font-weight: bold;
  text-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(251, 191, 36, 0.6);
}

.glory-path-overall-progress {
  position: relative;
  z-index: 1;
  margin-top: 12px;
}

.overall-progress-label {
  font-size: 12px;
  color: var(--chibi-text-muted);
  text-transform: uppercase;
  margin-bottom: 8px;
  text-align: center;
  font-weight: bold;
  letter-spacing: 1px;
}

.overall-progress-bar {
  position: relative;
  height: 20px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 10px;
  border: 2px solid rgba(192, 132, 252, 0.3);
  overflow: hidden;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.5);
}

.overall-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, 
    var(--chibi-gold) 0%,
    var(--chibi-extrapass) 50%,
    var(--chibi-gold) 100%);
  background-size: 200% 100%;
  border-radius: 8px;
  transition: width 0.5s ease;
  box-shadow: 
    0 0 20px rgba(251, 191, 36, 0.6),
    inset 0 0 10px rgba(255, 255, 255, 0.2);
  animation: progressShine 2s linear infinite;
}

@keyframes progressShine {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.overall-progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  font-weight: bold;
  color: var(--chibi-bg);
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
  z-index: 2;
}

.glory-path-road {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  max-height: 68vh;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 0;
  position: relative;
}

.glory-path-road::-webkit-scrollbar {
  width: 8px;
}

.glory-path-road::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}

.glory-path-road::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--chibi-gold), var(--chibi-extrapass));
  border-radius: 4px;
  box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

.glory-path-segment {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  width: 100%;
  padding-top: 8px;
  overflow: visible;
}

.glory-path-line {
  width: 8px;
  background: rgba(192, 132, 252, 0.15);
  border-radius: 4px;
  position: relative;
  margin: 0 auto;
  transition: all 0.5s ease;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.3);
}

.glory-path-line.filled {
  background: linear-gradient(180deg, 
    var(--chibi-gold) 0%,
    var(--chibi-extrapass) 30%,
    var(--chibi-gold) 60%,
    var(--chibi-extrapass) 100%);
  background-size: 100% 200%;
  box-shadow: 
    0 0 15px rgba(251, 191, 36, 0.6),
    inset 0 0 15px rgba(251, 191, 36, 0.4);
  animation: lineGlow 2s ease-in-out infinite;
}

@keyframes lineGlow {
  0%, 100% {
    box-shadow: 
      0 0 15px rgba(251, 191, 36, 0.6),
      inset 0 0 15px rgba(251, 191, 36, 0.4);
  }
  50% {
    box-shadow: 
      0 0 25px rgba(251, 191, 36, 0.8),
      inset 0 0 20px rgba(251, 191, 36, 0.6);
  }
}

.glory-path-line-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, 
    var(--chibi-gold) 0%,
    var(--chibi-extrapass) 100%);
  border-radius: 4px;
  transition: height 0.5s ease;
  box-shadow: 
    0 0 15px rgba(251, 191, 36, 0.6),
    inset 0 0 10px rgba(255, 255, 255, 0.2);
}

.glory-path-line-glow {
  position: absolute;
  top: -5px;
  left: -5px;
  right: -5px;
  bottom: -5px;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.4) 0%, transparent 70%);
  border-radius: 50%;
  animation: lineGlowPulse 2s ease-in-out infinite;
}

@keyframes lineGlowPulse {
  0%, 100% {
    opacity: 0.5;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

.glory-milestone-card {
  width: 260px;
  min-height: 110px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.95), rgba(192, 132, 252, 0.2));
  border: 3px solid var(--chibi-border);
  border-radius: 16px;
  padding: 12px;
  margin: 6px 0;
  position: relative;
  transition: all 0.3s ease;
  box-shadow: 
    0 4px 16px rgba(0, 0, 0, 0.5),
    inset 0 0 20px rgba(192, 132, 252, 0.1);
  overflow: visible;
}

.glory-milestone-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    transparent 0%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 100%);
  transition: left 0.5s ease;
}

.glory-milestone-card:hover::before {
  left: 100%;
}

.milestone-card-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at top right, rgba(192, 132, 252, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.glory-milestone-card.completed {
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.35), rgba(192, 132, 252, 0.25));
  border-color: rgba(76, 175, 80, 0.7);
  box-shadow: 
    0 4px 20px rgba(76, 175, 80, 0.5),
    0 0 30px rgba(76, 175, 80, 0.3),
    inset 0 0 20px rgba(76, 175, 80, 0.2);
}

.glory-milestone-card.next {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.4), rgba(245, 158, 11, 0.3));
  border-color: rgba(251, 191, 36, 0.9);
  box-shadow: 
    0 6px 28px rgba(251, 191, 36, 0.6),
    0 0 45px rgba(251, 191, 36, 0.4),
    inset 0 0 25px rgba(251, 191, 36, 0.2);
  animation: nextMilestonePulse 2s ease-in-out infinite;
  transform: scale(1.03);
}

.glory-milestone-card.locked {
  opacity: 0.4;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.4), rgba(192, 132, 252, 0.05));
  border-color: rgba(192, 132, 252, 0.15);
  filter: grayscale(0.5);
}

@keyframes nextMilestonePulse {
  0%, 100% {
    box-shadow: 
      0 6px 28px rgba(251, 191, 36, 0.6),
      0 0 45px rgba(251, 191, 36, 0.4),
      inset 0 0 25px rgba(251, 191, 36, 0.2);
    transform: scale(1.03);
  }
  50% {
    box-shadow: 
      0 8px 36px rgba(251, 191, 36, 0.8),
      0 0 60px rgba(251, 191, 36, 0.6),
      inset 0 0 30px rgba(251, 191, 36, 0.3);
    transform: scale(1.06);
  }
}

.milestone-league-header {
  margin-bottom: 8px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.milestone-league-badge-large {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, rgba(192, 132, 252, 0.5), rgba(96, 165, 250, 0.5));
  border: 2px solid rgba(192, 132, 252, 0.7);
  border-radius: 10px;
  padding: 5px 12px;
  font-weight: bold;
  box-shadow: 
    0 2px 12px rgba(192, 132, 252, 0.5),
    inset 0 0 10px rgba(255, 255, 255, 0.1);
  position: relative;
  overflow: hidden;
}

.milestone-league-badge-large::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, 
    transparent 30%,
    rgba(255, 255, 255, 0.2) 50%,
    transparent 70%);
  animation: badgeShine 3s linear infinite;
}

@keyframes badgeShine {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
  }
}

.league-emoji-badge {
  font-size: 18px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.league-name-badge {
  font-size: 13px;
  color: var(--chibi-text);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  position: relative;
  z-index: 1;
}

.league-unlock-text {
  font-size: 10px;
  color: var(--chibi-gold);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: bold;
  text-shadow: 0 2px 4px rgba(251, 191, 36, 0.5);
  animation: unlockTextPulse 2s ease-in-out infinite;
}

@keyframes unlockTextPulse {
  0%, 100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

.milestone-main-content {
  position: relative;
  z-index: 1;
}

.milestone-trophy-value {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 20px;
  font-weight: bold;
  color: var(--chibi-gold);
  text-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(251, 191, 36, 0.6);
}

.trophy-icon-card {
  font-size: 26px;
  filter: drop-shadow(0 2px 8px rgba(251, 191, 36, 0.8));
  animation: trophyBounce 3s ease-in-out infinite;
}

@keyframes trophyBounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-3px);
  }
}

.milestone-trophies-value {
  font-size: 24px;
}

.milestone-remaining {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--chibi-text-muted);
  background: rgba(0, 0, 0, 0.3);
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid rgba(192, 132, 252, 0.2);
}

.remaining-icon {
  font-size: 14px;
}

.remaining-text {
  font-weight: bold;
}

.milestone-rewards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.milestone-reward-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: rgba(192, 132, 252, 0.15);
  border: 2px solid rgba(192, 132, 252, 0.4);
  border-radius: 10px;
  padding: 8px 6px;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.milestone-reward-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, 
    rgba(255, 255, 255, 0.1) 0%,
    transparent 50%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.milestone-reward-card:hover::before {
  opacity: 1;
}

.glory-milestone-card.completed .milestone-reward-card {
  background: rgba(76, 175, 80, 0.25);
  border-color: rgba(76, 175, 80, 0.6);
  box-shadow: 0 0 10px rgba(76, 175, 80, 0.3);
}

.glory-milestone-card.next .milestone-reward-card {
  background: rgba(251, 191, 36, 0.25);
  border-color: rgba(251, 191, 36, 0.7);
  box-shadow: 
    0 0 15px rgba(251, 191, 36, 0.4),
    inset 0 0 10px rgba(251, 191, 36, 0.2);
}

.reward-icon-large {
  font-size: 28px;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));
  position: relative;
  z-index: 1;
}

.reward-amount-large {
  font-size: 14px;
  font-weight: bold;
  color: var(--chibi-text);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
  position: relative;
  z-index: 1;
}

.reward-type-label {
  font-size: 9px;
  color: var(--chibi-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: relative;
  z-index: 1;
}

.milestone-checkmark {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, #4CAF50, #45a049);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  box-shadow: 
    0 2px 8px rgba(76, 175, 80, 0.6),
    0 0 20px rgba(76, 175, 80, 0.4);
}

.checkmark-icon {
  color: white;
  font-size: 18px;
  font-weight: bold;
  position: relative;
  z-index: 2;
}

.checkmark-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background: radial-gradient(circle, rgba(76, 175, 80, 0.6) 0%, transparent 70%);
  border-radius: 50%;
  animation: checkmarkGlow 2s ease-in-out infinite;
}

@keyframes checkmarkGlow {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.6;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 1;
  }
}

.milestone-next-indicator {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--chibi-gold), var(--chibi-extrapass));
  color: var(--chibi-bg);
  font-size: 10px;
  font-weight: bold;
  padding: 4px 14px;
  border-radius: 12px;
  box-shadow: 
    0 2px 10px rgba(251, 191, 36, 0.6),
    0 0 20px rgba(251, 191, 36, 0.4);
  text-transform: uppercase;
  letter-spacing: 1px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 6px;
  animation: nextIndicatorPulse 1.5s ease-in-out infinite;
}

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

.next-indicator-arrow {
  font-size: 12px;
  animation: arrowBounce 1s ease-in-out infinite;
}

@keyframes arrowBounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(3px);
  }
}

@keyframes nextIndicatorPulse {
  0%, 100% {
    transform: translateX(-50%) scale(1);
    box-shadow: 
      0 2px 10px rgba(251, 191, 36, 0.6),
      0 0 20px rgba(251, 191, 36, 0.4);
  }
  50% {
    transform: translateX(-50%) scale(1.1);
    box-shadow: 
      0 4px 15px rgba(251, 191, 36, 0.8),
      0 0 30px rgba(251, 191, 36, 0.6);
  }
}

.milestone-lock-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  backdrop-filter: blur(2px);
}

.lock-icon {
  font-size: 32px;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
  opacity: 0.7;
}

/* Стили для детального просмотра товара */
.item-detail-modal-content {
  max-width: 600px;
}

.item-detail-body {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.item-detail-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.item-detail-image-large {
  width: 200px;
  height: 200px;
  border-radius: 20px;
  margin: 0 auto;
}

.item-detail-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.item-detail-name {
  font-size: 28px;
  font-weight: 700;
  color: var(--chibi-text);
  text-align: center;
}

.item-detail-description {
  font-size: 16px;
  color: var(--chibi-text-muted);
  text-align: center;
  line-height: 1.6;
}

.item-detail-features {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 8px;
}

.item-detail-feature {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(45, 27, 78, 0.6), rgba(192, 132, 252, 0.1));
  border: 1px solid var(--chibi-border);
  border-radius: 12px;
  transition: all 0.3s;
}

.item-detail-feature:hover {
  border-color: var(--chibi-purple);
  transform: translateX(4px);
}

.feature-icon {
  font-size: 32px;
  flex-shrink: 0;
}

.feature-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.feature-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--chibi-text);
}

.feature-desc {
  font-size: 14px;
  color: var(--chibi-text-muted);
  line-height: 1.5;
}

.item-detail-rewards {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.1), rgba(239, 68, 68, 0.05));
  border: 2px solid var(--chibi-gold);
  border-radius: 16px;
  margin-top: 8px;
}

.item-detail-rewards-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--chibi-gold);
  text-align: center;
  margin-bottom: 8px;
}

.item-detail-reward-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(45, 27, 78, 0.4);
  border-radius: 10px;
}

.item-detail-reward-item .reward-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.item-detail-reward-item .reward-text {
  font-size: 15px;
  color: var(--chibi-text);
  font-weight: 500;
}

.item-detail-footer {
  padding-top: 20px;
  border-top: 1px solid var(--chibi-border);
}

.item-detail-buy-btn {
  width: 100%;
  padding: 16px 24px;
  background: linear-gradient(135deg, var(--chibi-gold), var(--chibi-orange));
  border: none;
  border-radius: 12px;
  color: var(--chibi-bg);
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.item-detail-buy-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(251, 191, 36, 0.5);
}

.item-detail-buy-btn:active {
  transform: translateY(0);
}

.item-detail-buy-btn .price-icon {
  font-size: 22px;
}

.item-detail-buy-btn .price-value {
  font-size: 20px;
  color: var(--chibi-bg);
  font-weight: 700;
}
