.shop-chest-section {
  position: relative;
  margin: 22px 0 28px;
  padding: clamp(18px, 2.4vw, 30px);
  overflow: hidden;
  border: 1px solid rgba(55, 181, 255, .2);
  border-radius: 24px;
  background:
    radial-gradient(circle at 15% 0, rgba(0, 212, 255, .12), transparent 38%),
    radial-gradient(circle at 90% 85%, rgba(123, 65, 255, .14), transparent 42%),
    linear-gradient(145deg, rgba(8, 22, 42, .98), rgba(3, 10, 23, .98));
  box-shadow: inset 0 1px rgba(255, 255, 255, .04), 0 22px 50px rgba(0, 0, 0, .24);
}

.shop-chest-section::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .22;
  background-image: linear-gradient(rgba(42, 179, 255, .11) 1px, transparent 1px), linear-gradient(90deg, rgba(42, 179, 255, .11) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

.shop-chest-heading {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.shop-chest-heading h2 {
  margin: 3px 0 8px;
  color: #f5f9ff;
  font-size: clamp(26px, 3vw, 42px);
  line-height: 1;
}

.shop-chest-heading p:last-child {
  max-width: 760px;
  margin: 0;
  color: #91a7c2;
  line-height: 1.55;
}

.shop-chest-reset {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 13px;
  border: 1px solid rgba(59, 205, 255, .25);
  border-radius: 999px;
  color: #aeeeff;
  background: rgba(5, 22, 42, .72);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.shop-chest-reset i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #2ee7ff;
  box-shadow: 0 0 14px #2ee7ff;
  animation: shop-chest-reset-pulse 1.8s ease-in-out infinite;
}

.shop-chest-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.shop-chest-card {
  --chest-accent: #2ddcff;
  position: relative;
  display: grid;
  grid-template-columns: minmax(190px, .76fr) minmax(250px, 1fr);
  min-height: 330px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--chest-accent) 40%, transparent);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(8, 24, 45, .97), rgba(3, 9, 20, .98));
  box-shadow: inset 0 0 32px color-mix(in srgb, var(--chest-accent) 7%, transparent);
  isolation: isolate;
}

.shop-chest-card[data-rarity="rare"] { --chest-accent: #34b7ff; }
.shop-chest-card[data-rarity="epic"] { --chest-accent: #a46cff; }
.shop-chest-card[data-rarity="legendary"] { --chest-accent: #ffb12d; }
.shop-chest-card[data-rarity="mythic"] { --chest-accent: #ff4dd8; }
.shop-chest-card[data-rarity="ancestral"] { --chest-accent: #ff5b2d; }
.shop-chest-card[data-rarity="divin"] { --chest-accent: #ffe069; }

.shop-chest-card::before {
  content: "";
  position: absolute;
  inset: -40%;
  z-index: -1;
  opacity: .24;
  background: conic-gradient(from 30deg, transparent, var(--chest-accent), transparent 28%, transparent 70%, var(--chest-accent), transparent);
  animation: shop-chest-aura 16s linear infinite;
}

.shop-chest-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 300px;
  overflow: hidden;
}

.shop-chest-visual::before,
.shop-chest-visual::after {
  content: "";
  position: absolute;
  left: 50%;
  border: 1px solid color-mix(in srgb, var(--chest-accent) 40%, transparent);
  border-radius: 50%;
  transform: translateX(-50%) rotateX(68deg);
}

.shop-chest-visual::before {
  bottom: 25px;
  width: 78%;
  height: 36%;
  box-shadow: 0 0 35px color-mix(in srgb, var(--chest-accent) 22%, transparent), inset 0 0 24px color-mix(in srgb, var(--chest-accent) 15%, transparent);
  animation: shop-chest-ring 3.4s ease-in-out infinite;
}

.shop-chest-visual::after {
  bottom: 42px;
  width: 55%;
  height: 25%;
  border-style: dashed;
  animation: shop-chest-ring 3.4s .5s ease-in-out infinite reverse;
}

.shop-chest-image {
  position: relative;
  z-index: 2;
  width: min(105%, 330px);
  max-height: 300px;
  object-fit: contain;
  filter: drop-shadow(0 18px 20px rgba(0, 0, 0, .5)) drop-shadow(0 0 25px color-mix(in srgb, var(--chest-accent) 28%, transparent));
  animation: shop-chest-float 4.2s ease-in-out infinite;
}

.shop-chest-free-mark {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 4;
  padding: 7px 11px;
  border: 1px solid rgba(101, 255, 194, .4);
  border-radius: 999px;
  color: #8fffd0;
  background: rgba(4, 40, 34, .82);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .08em;
}

.shop-chest-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 11px;
  padding: 28px 26px 28px 8px;
}

.shop-chest-kicker {
  color: var(--chest-accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.shop-chest-copy h3 {
  margin: 0;
  color: #f6f9ff;
  font-size: clamp(23px, 2vw, 31px);
  line-height: 1.05;
}

.shop-chest-copy > p {
  min-height: 45px;
  margin: 0;
  color: #9aadc4;
  font-size: 13px;
  line-height: 1.55;
}

.shop-chest-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.shop-chest-meta span {
  padding: 6px 9px;
  border: 1px solid rgba(139, 171, 207, .18);
  border-radius: 9px;
  color: #b8c9dd;
  background: rgba(2, 12, 25, .65);
  font-size: 11px;
  font-weight: 800;
}

.shop-chest-actions {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 9px;
  margin-top: 4px;
}

.shop-chest-info,
.shop-chest-open {
  min-height: 44px;
  border-radius: 12px;
  font-weight: 900;
  cursor: pointer;
}

.shop-chest-info {
  width: 44px;
  border: 1px solid color-mix(in srgb, var(--chest-accent) 38%, transparent);
  color: var(--chest-accent);
  background: color-mix(in srgb, var(--chest-accent) 8%, #07101e);
  font-size: 18px;
}

.shop-chest-open {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid color-mix(in srgb, var(--chest-accent) 68%, #fff 15%);
  color: #06101d;
  background: linear-gradient(135deg, color-mix(in srgb, var(--chest-accent) 82%, #fff), var(--chest-accent));
  box-shadow: 0 9px 24px color-mix(in srgb, var(--chest-accent) 24%, transparent);
}

.shop-chest-open img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.shop-chest-open:disabled {
  cursor: not-allowed;
  color: #77889e;
  border-color: rgba(116, 139, 166, .18);
  background: #101b2b;
  box-shadow: none;
}

.shop-chest-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  padding: 18px;
}

.shop-chest-modal[hidden] { display: none !important; }

.shop-chest-modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 5, 14, .84);
  backdrop-filter: blur(12px);
}

.shop-chest-dialog {
  position: relative;
  width: min(720px, 100%);
  max-height: min(820px, calc(100dvh - 36px));
  overflow: auto;
  padding: 25px;
  border: 1px solid rgba(52, 194, 255, .28);
  border-radius: 22px;
  background: linear-gradient(145deg, #0b1b31, #050d1b);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .65);
}

.shop-chest-dialog h2 { margin: 4px 0 7px; color: #f7faff; }
.shop-chest-dialog header > p:last-child { margin: 0; color: #8fa4be; line-height: 1.5; }
.shop-chest-dialog .modal-close { position: absolute; top: 12px; right: 12px; }

.shop-chest-odds-list {
  display: grid;
  gap: 9px;
  margin: 20px 0;
}

.shop-chest-odds-row,
.shop-chest-result {
  --reward-accent: #7f98b8;
  position: relative;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  padding: 11px 13px;
  border: 1px solid color-mix(in srgb, var(--reward-accent) 34%, transparent);
  border-radius: 13px;
  background: color-mix(in srgb, var(--reward-accent) 6%, #071323);
}

.shop-chest-odds-row[data-rarity="rare"], .shop-chest-result[data-rarity="rare"] { --reward-accent: #39baff; }
.shop-chest-odds-row[data-rarity="epic"], .shop-chest-result[data-rarity="epic"] { --reward-accent: #a26bff; }
.shop-chest-odds-row[data-rarity="legendary"], .shop-chest-result[data-rarity="legendary"] { --reward-accent: #ffb32c; }
.shop-chest-odds-row[data-rarity="mythic"], .shop-chest-result[data-rarity="mythic"] { --reward-accent: #ff55db; }
.shop-chest-odds-row[data-rarity="ancestral"], .shop-chest-result[data-rarity="ancestral"] { --reward-accent: #ff612f; }
.shop-chest-odds-row[data-rarity="divin"], .shop-chest-result[data-rarity="divin"] { --reward-accent: #ffe469; }

.shop-chest-reward-icon {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  border-radius: 11px;
  color: var(--reward-accent);
  background: color-mix(in srgb, var(--reward-accent) 12%, #071120);
  box-shadow: inset 0 0 18px color-mix(in srgb, var(--reward-accent) 12%, transparent);
  font-weight: 950;
}

.shop-chest-reward-icon img { width: 62px; height: 62px; object-fit: contain; }
.shop-chest-odds-copy { min-width: 0; }
.shop-chest-odds-copy strong { display: block; color: #edf4ff; }
.shop-chest-odds-copy small { display: block; margin-top: 3px; color: #7f94ae; }
.shop-chest-odds-rate { color: var(--reward-accent); font-size: 17px; font-weight: 950; }
.shop-chest-dialog footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #71849c; }

.shop-chest-opening-modal {
  --chest-reveal-accent: #985cff;
  --chest-reveal-gold: #efbd70;
  overflow: hidden;
  padding: clamp(8px, 1.4vw, 20px);
  background: rgba(0, 4, 14, .93);
  isolation: isolate;
}

.shop-chest-opening-modal .shop-chest-modal-backdrop { display: none; }

.shop-chest-opening-dialog {
  position: relative;
  width: min(1180px, calc(100vw - 24px));
  height: min(885px, calc(100dvh - 24px));
  min-height: 620px;
  display: grid;
  grid-template-rows: auto minmax(190px, 1fr) minmax(190px, .86fr) auto;
  align-content: stretch;
  overflow: hidden;
  padding: clamp(34px, 4.2vw, 62px) clamp(30px, 6vw, 88px) clamp(24px, 2.8vw, 42px);
  border: 1px solid rgba(238, 187, 107, .58);
  border-radius: 4px;
  background:
    linear-gradient(180deg, rgba(1, 8, 25, .08), rgba(3, 4, 18, .2)),
    url('/public/assets/shop/chests/chest-reveal-divine-bg-v1.webp?v=20260804chestreveal1') center / cover no-repeat,
    #030816;
  box-shadow: 0 36px 120px rgba(0, 0, 0, .86), inset 0 0 70px rgba(80, 38, 190, .12);
  color: #f8f5ff;
  isolation: isolate;
}

.shop-chest-opening-dialog::before,
.shop-chest-opening-dialog::after {
  content: "";
  position: absolute;
  z-index: 1;
  pointer-events: none;
}

.shop-chest-opening-dialog::before {
  inset: 0;
  background: linear-gradient(180deg, rgba(1, 6, 19, .5) 0%, rgba(3, 4, 17, .06) 32%, rgba(7, 4, 24, .02) 70%, rgba(1, 3, 12, .48) 100%);
}

.shop-chest-opening-dialog::after {
  left: 50%;
  bottom: 2.5%;
  width: min(660px, 70%);
  height: 24%;
  border-radius: 50%;
  opacity: .72;
  transform: translateX(-50%);
  background: radial-gradient(ellipse, color-mix(in srgb, var(--chest-reveal-accent) 74%, white) 0%, color-mix(in srgb, var(--chest-reveal-accent) 38%, transparent) 36%, transparent 72%);
  filter: blur(22px);
  animation: shop-chest-floor-glow 1.9s ease-in-out infinite;
}

.shop-chest-opening-vignette {
  position: absolute;
  z-index: 2;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 58%, transparent 25%, rgba(0, 3, 15, .24) 72%, rgba(0, 2, 10, .74) 100%);
}

.shop-chest-opening-header {
  position: relative;
  z-index: 8;
  min-width: 0;
  text-align: center;
  text-transform: uppercase;
}

.shop-chest-opening-header .eyebrow {
  margin: 0 0 5px;
  color: #44dcff;
  font-size: clamp(11px, 1.25vw, 17px);
  font-weight: 950;
  letter-spacing: clamp(4px, .65vw, 9px);
  text-shadow: 0 0 18px rgba(51, 216, 255, .7);
}

.shop-chest-opening-header h2 {
  margin: 0;
  color: #fff1d3;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(28px, 4vw, 54px);
  font-weight: 700;
  letter-spacing: .035em;
  line-height: 1.04;
  text-shadow: 0 2px 0 #6b3816, 0 0 18px rgba(255, 211, 136, .34), 0 5px 18px rgba(0, 0, 0, .9);
}

.shop-chest-opening-divider {
  position: relative;
  display: block;
  width: min(490px, 72%);
  height: 24px;
  margin: 8px auto 1px;
}

.shop-chest-opening-divider::before,
.shop-chest-opening-divider::after {
  content: "";
  position: absolute;
  top: 11px;
  width: calc(50% - 16px);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(239, 189, 112, .9));
}

.shop-chest-opening-divider::before { left: 0; }
.shop-chest-opening-divider::after { right: 0; transform: scaleX(-1); }
.shop-chest-opening-divider i {
  position: absolute;
  top: 6px;
  left: 50%;
  width: 11px;
  height: 11px;
  border: 1px solid #ffe7a8;
  transform: translateX(-50%) rotate(45deg);
  background: #8b31ff;
  box-shadow: 0 0 16px #9d49ff;
}

.shop-chest-opening-rewards {
  position: relative;
  z-index: 9;
  width: min(760px, 88%);
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2vw, 24px);
  margin: 4px auto 0;
  text-align: center;
}

.shop-chest-opening-rewards .shop-chest-result {
  --reward-accent: #9a5cff;
  position: relative;
  min-width: 0;
  min-height: clamp(190px, 25vh, 250px);
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: minmax(96px, 1fr) auto;
  place-items: center;
  gap: 9px;
  overflow: visible;
  padding: clamp(16px, 2vw, 25px) clamp(12px, 1.8vw, 22px);
  border: 2px solid color-mix(in srgb, var(--reward-accent) 78%, #d7e8ff);
  border-radius: 5px;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--reward-accent) 18%, rgba(9, 8, 47, .91)), rgba(6, 8, 35, .92)),
    radial-gradient(circle at 50% 25%, color-mix(in srgb, var(--reward-accent) 28%, transparent), transparent 58%);
  box-shadow:
    0 0 0 3px rgba(19, 103, 220, .42),
    0 0 30px color-mix(in srgb, var(--reward-accent) 58%, transparent),
    inset 0 0 34px color-mix(in srgb, var(--reward-accent) 15%, transparent);
  clip-path: polygon(6% 0, 94% 0, 100% 7%, 100% 91%, 94% 100%, 6% 100%, 0 91%, 0 7%);
  opacity: 0;
  transform: translateY(20px) scale(.92);
}

.shop-chest-opening-rewards .shop-chest-result::before,
.shop-chest-opening-rewards .shop-chest-result::after {
  content: "";
  position: absolute;
  z-index: 4;
  left: 50%;
  width: 16px;
  height: 16px;
  border: 2px solid #ffe6a1;
  transform: translateX(-50%) rotate(45deg);
  background: color-mix(in srgb, var(--reward-accent) 72%, #1d38ff);
  box-shadow: 0 0 14px var(--reward-accent);
}

.shop-chest-opening-rewards .shop-chest-result::before { top: -9px; }
.shop-chest-opening-rewards .shop-chest-result::after { bottom: -9px; }

.shop-chest-opening-rewards .shop-chest-reward-icon {
  width: clamp(102px, 10vw, 138px);
  height: clamp(102px, 10vw, 138px);
  border: 0;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--reward-accent) 18%, transparent), transparent 70%);
  box-shadow: 0 0 30px color-mix(in srgb, var(--reward-accent) 36%, transparent);
}

.shop-chest-opening-rewards .shop-chest-reward-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 12px color-mix(in srgb, var(--reward-accent) 72%, transparent));
}

.shop-chest-opening-rewards .shop-chest-reward-icon.is-frame-preview {
  width: clamp(108px, 11vw, 146px);
  height: clamp(108px, 11vw, 146px);
}

.shop-chest-opening-rewards .shop-chest-result > div {
  min-width: 0;
  align-self: end;
}

.shop-chest-opening-rewards .shop-chest-result strong {
  display: block;
  overflow: hidden;
  color: #fff;
  font-size: clamp(15px, 1.65vw, 22px);
  font-weight: 950;
  line-height: 1.12;
  text-overflow: ellipsis;
  text-shadow: 0 2px 7px rgba(0, 0, 0, .9);
}

.shop-chest-opening-rewards .shop-chest-result small {
  display: block;
  margin-top: 7px;
  color: color-mix(in srgb, var(--reward-accent) 68%, #f7e6ff);
  font-size: clamp(12px, 1.25vw, 17px);
  font-weight: 950;
  line-height: 1.2;
  text-shadow: 0 0 12px color-mix(in srgb, var(--reward-accent) 42%, transparent);
}

.shop-chest-opening-rewards .shop-chest-result.is-pending {
  opacity: .55;
  transform: none;
  animation: shop-chest-pending 1s ease-in-out infinite;
}

.shop-chest-opening-rewards .shop-chest-result.is-pending::before,
.shop-chest-opening-rewards .shop-chest-result.is-pending::after { opacity: .45; }

.shop-chest-pending-orb {
  width: 92px;
  height: 92px;
  border: 2px solid rgba(157, 92, 255, .55);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .8), rgba(132, 56, 255, .24) 22%, transparent 68%);
  box-shadow: 0 0 45px rgba(137, 62, 255, .55);
}

.shop-chest-pending-line {
  width: 72%;
  height: 12px;
  border-radius: 20px;
  background: linear-gradient(90deg, rgba(133, 66, 255, .15), rgba(216, 186, 255, .7), rgba(133, 66, 255, .15));
}

.shop-chest-opening-modal.is-revealed .shop-chest-result {
  animation: shop-chest-reveal-card .34s calc(var(--reward-index, 0) * 70ms) cubic-bezier(.18, .86, .26, 1.2) forwards;
}

.shop-chest-opening-stage {
  position: relative;
  z-index: 7;
  min-height: 185px;
  display: grid;
  place-items: end center;
  margin-top: -4px;
}

.shop-chest-opening-image {
  position: relative;
  z-index: 5;
  width: min(440px, 46vw);
  max-height: min(250px, 28vh);
  object-fit: contain;
  transform-origin: 50% 82%;
  filter: drop-shadow(0 22px 24px rgba(0, 0, 0, .74)) drop-shadow(0 0 28px var(--chest-reveal-accent));
  will-change: transform, filter;
}

.shop-chest-opening-modal.is-opening .shop-chest-opening-image {
  animation: shop-chest-awaken .56s cubic-bezier(.22, .78, .25, 1) both, shop-chest-hover 2.4s .56s ease-in-out infinite;
}

.shop-chest-opening-modal.is-revealed .shop-chest-opening-image {
  animation: shop-chest-reveal-impact .42s cubic-bezier(.18, .8, .28, 1.25) both, shop-chest-hover 2.4s .42s ease-in-out infinite;
}

.shop-chest-burst,
.shop-chest-opening-rays {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: 5%;
  pointer-events: none;
  transform: translateX(-50%);
}

.shop-chest-burst {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  opacity: 0;
  background: #fff;
}

.shop-chest-opening-rays {
  width: min(720px, 82vw);
  height: 220px;
  opacity: .55;
  background: repeating-conic-gradient(from -14deg at 50% 100%, transparent 0 7deg, rgba(188, 115, 255, .28) 8deg 10deg, transparent 11deg 18deg);
  clip-path: polygon(8% 100%, 92% 100%, 67% 0, 33% 0);
  filter: blur(2px);
  animation: shop-chest-rays 3.8s linear infinite;
}

.shop-chest-opening-modal.is-opening .shop-chest-burst {
  animation: shop-chest-burst .44s .08s ease-out forwards;
}

.shop-chest-opening-particles {
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 12% 68%, #d8adff 0 2px, transparent 3px),
    radial-gradient(circle at 28% 38%, #4fcfff 0 2px, transparent 3px),
    radial-gradient(circle at 78% 61%, #e4bcff 0 2px, transparent 3px),
    radial-gradient(circle at 90% 31%, #7d5cff 0 2px, transparent 3px),
    radial-gradient(circle at 56% 17%, #fff 0 1px, transparent 2px);
  background-size: 170px 150px, 210px 180px, 190px 130px, 230px 170px, 140px 120px;
  opacity: .72;
  animation: shop-chest-particles 5s linear infinite;
}

.shop-chest-opening-footer {
  position: relative;
  z-index: 10;
  display: grid;
  justify-items: center;
  gap: 7px;
  margin-top: -2px;
}

.shop-chest-opening-footer p {
  min-height: 16px;
  margin: 0;
  color: rgba(221, 231, 255, .74);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.shop-chest-claim {
  position: relative;
  width: min(350px, 78vw);
  min-height: 66px;
  padding: 13px 44px 16px;
  border: 2px solid #ffd48a;
  clip-path: polygon(9% 0, 91% 0, 100% 50%, 91% 100%, 9% 100%, 0 50%);
  color: #fff8e8;
  background: linear-gradient(180deg, #f69035 0%, #d24c14 55%, #9a2909 100%);
  box-shadow: 0 0 0 4px rgba(77, 30, 10, .75), 0 0 30px rgba(255, 112, 30, .52), inset 0 2px 0 rgba(255, 255, 255, .4);
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 800;
  text-shadow: 0 2px 2px rgba(77, 19, 0, .8);
  cursor: pointer;
  transition: transform .16s ease, filter .16s ease;
}

.shop-chest-claim::after {
  content: "";
  position: absolute;
  inset: 6px 18px;
  border: 1px solid rgba(255, 230, 176, .58);
  clip-path: inherit;
  pointer-events: none;
}

.shop-chest-claim:hover:not(:disabled) { transform: translateY(-2px) scale(1.015); filter: brightness(1.12); }
.shop-chest-claim:disabled { opacity: .42; cursor: wait; filter: grayscale(.35); }

.shop-chest-opening-error {
  grid-column: 1 / -1;
  width: min(560px, 100%);
  margin: auto;
  padding: 18px 20px;
  border: 1px solid rgba(255, 75, 120, .55);
  border-radius: 12px;
  color: #ffb8cb;
  background: rgba(63, 4, 27, .86);
  box-shadow: 0 0 30px rgba(255, 39, 101, .18);
  text-align: center;
}

.shop-chest-opening-modal.has-error .shop-chest-opening-image { filter: grayscale(.45) brightness(.6); }
.shop-chest-opening-modal.has-error .shop-chest-opening-rays { opacity: .12; }

@keyframes shop-chest-awaken {
  0% { opacity: .55; transform: translateY(34px) scale(.82); filter: brightness(.45) drop-shadow(0 10px 20px #000); }
  55% { opacity: 1; transform: translateY(-8px) scale(1.08); filter: brightness(1.5) drop-shadow(0 0 45px var(--chest-reveal-accent)); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes shop-chest-reveal-impact {
  0% { transform: scale(.94) translateY(8px); }
  55% { transform: scale(1.08) translateY(-7px); filter: brightness(1.65) drop-shadow(0 0 48px var(--chest-reveal-accent)); }
  100% { transform: scale(1) translateY(0); }
}
@keyframes shop-chest-hover { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes shop-chest-floor-glow { 50% { opacity: 1; transform: translateX(-50%) scale(1.08); } }
@keyframes shop-chest-rays { to { transform: translateX(-50%) rotate(.001deg) scale(1.04); } }
@keyframes shop-chest-particles { to { background-position: 20px -90px, -30px -70px, 40px -110px, -20px -80px, 10px -100px; } }
@keyframes shop-chest-pending { 50% { opacity: .82; filter: brightness(1.2); } }
@keyframes shop-chest-reveal-card {
  0% { opacity: 0; transform: translateY(20px) scale(.92); filter: brightness(2); }
  70% { opacity: 1; transform: translateY(-3px) scale(1.025); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: brightness(1); }
}
.admin-chest-builder {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 13px;
}

.admin-chest-builder > label,
.admin-chest-reward-row > label {
  display: grid;
  align-content: start;
  gap: 6px;
}

.admin-chest-builder label > span,
.admin-chest-reward-row label > span {
  color: #9fb1c8;
  font-size: 11px;
  font-weight: 800;
}

.admin-chest-builder input,
.admin-chest-builder textarea,
.admin-chest-builder select,
.admin-chest-reward-row input,
.admin-chest-reward-row select {
  min-width: 0;
  width: 100%;
}

.admin-chest-reward-editor {
  padding: 16px;
  border: 1px solid rgba(55, 184, 255, .18);
  border-radius: 16px;
  background: rgba(3, 13, 27, .65);
}

.admin-chest-reward-editor > header,
.admin-chest-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-chest-reward-editor > header strong,
.admin-chest-reward-editor > header small { display: block; }
.admin-chest-reward-editor > header small { margin-top: 4px; color: #71859f; }
.admin-chest-reward-actions { display: flex; align-items: center; gap: 8px; }

#admin-chest-rewards { display: grid; gap: 12px; margin-top: 14px; }

.admin-chest-reward-row {
  position: relative;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 9px;
  padding: 13px 46px 13px 13px;
  border: 1px solid rgba(117, 153, 190, .16);
  border-radius: 13px;
  background: rgba(5, 18, 35, .72);
}

.admin-chest-reward-row .wide { grid-column: span 2; }
.admin-chest-reward-row .reward-reference { grid-column: span 2; }
.admin-chest-remove-reward {
  position: absolute;
  top: 11px;
  right: 10px;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(255, 85, 112, .28);
  border-radius: 8px;
  color: #ff718a;
  background: rgba(80, 12, 29, .32);
  cursor: pointer;
}

.admin-chest-rate-total { margin: 11px 0 0; color: #59dcff; font-size: 12px; font-weight: 800; }

.admin-chest-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.admin-chest-card {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(55, 184, 255, .18);
  border-radius: 16px;
  background: rgba(4, 15, 29, .68);
}

.admin-chest-card > img { width: 130px; height: 130px; object-fit: contain; }
.admin-chest-card-copy { min-width: 0; }
.admin-chest-card-copy > span { color: #5ee4ff; font-size: 10px; font-weight: 900; letter-spacing: .08em; }
.admin-chest-card-copy > strong { display: block; margin: 4px 0; color: #f3f7ff; }
.admin-chest-card-copy > small { color: #8095ae; }
.admin-chest-card-copy > p { margin: 8px 0; color: #a6b7ca; font-size: 12px; line-height: 1.45; }
.admin-chest-card-actions { display: flex; flex-wrap: wrap; gap: 8px; }

.shop-chest-reward-icon.is-frame-preview {
  position: relative;
  overflow: visible;
  border-radius: 50%;
}

.shop-chest-preview-avatar,
.shop-chest-preview-frame {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
}

.shop-chest-preview-avatar {
  width: 47px !important;
  height: 47px !important;
  border-radius: 50%;
  object-fit: cover !important;
}

.shop-chest-preview-frame {
  z-index: 2;
  width: 70px !important;
  height: 70px !important;
  object-fit: contain !important;
  filter: drop-shadow(0 0 8px var(--reward-accent));
}

.shop-chest-jackpots {
  position: relative;
  z-index: 1;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(65, 190, 255, .18);
}

.shop-chest-jackpots > header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 13px;
}

.shop-chest-jackpots h3 {
  margin: 2px 0 0;
  color: #f4f8ff;
  font-size: clamp(19px, 2vw, 25px);
}

.shop-chest-jackpots > header > span {
  color: #5fe5ff;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.shop-chest-jackpot-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 10px;
}

.shop-chest-jackpot-card {
  --reward-accent: #ffb32c;
  display: grid;
  grid-template-columns: 52px minmax(0, .82fr) minmax(150px, 1fr);
  align-items: center;
  gap: 11px;
  padding: 11px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--reward-accent) 34%, transparent);
  border-radius: 15px;
  background: linear-gradient(125deg, color-mix(in srgb, var(--reward-accent) 8%, #071426), #050d19);
}

.shop-chest-jackpot-card[data-rarity="mythic"] { --reward-accent: #ff55db; }
.shop-chest-jackpot-card[data-rarity="ancestral"] { --reward-accent: #ff612f; }
.shop-chest-jackpot-card[data-rarity="divin"] { --reward-accent: #ffe469; }

.shop-chest-jackpot-avatar {
  width: 52px;
  height: 52px;
  border: 2px solid var(--reward-accent);
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 18px color-mix(in srgb, var(--reward-accent) 32%, transparent);
}

.shop-chest-jackpot-identity,
.shop-chest-jackpot-reward > span { min-width: 0; }
.shop-chest-jackpot-identity strong,
.shop-chest-jackpot-reward strong { display: block; overflow: hidden; color: #f2f7ff; text-overflow: ellipsis; white-space: nowrap; }
.shop-chest-jackpot-identity small,
.shop-chest-jackpot-reward small { display: block; margin-top: 3px; overflow: hidden; color: #8198b3; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.shop-chest-jackpot-reward { display: grid; grid-template-columns: 42px minmax(0, 1fr); align-items: center; gap: 8px; }
.shop-chest-jackpot-reward .shop-chest-reward-icon { width: 42px; height: 42px; }
.shop-chest-jackpot-reward .shop-chest-reward-icon img { width: 38px; height: 38px; }
.shop-chest-jackpot-empty { grid-column: 1 / -1; margin: 0; padding: 16px; border: 1px dashed rgba(85, 187, 255, .2); border-radius: 13px; color: #8297b0; text-align: center; }

.header-notification-item.shop-chest-reward,
.notification-toast.shop-chest-reward {
  border-color: rgba(158, 91, 255, .42);
  background: linear-gradient(125deg, rgba(95, 34, 180, .19), rgba(5, 17, 38, .96));
  box-shadow: inset 0 0 24px rgba(114, 56, 255, .08);
}

.header-notification-icon.rich-image,
.notification-toast-rich-image {
  overflow: hidden;
  padding: 2px;
  border-color: rgba(186, 127, 255, .58);
  background: radial-gradient(circle, rgba(132, 70, 255, .26), rgba(5, 14, 32, .92));
  box-shadow: 0 0 16px rgba(132, 70, 255, .24);
}

.header-notification-icon.rich-image img,
.notification-toast-rich-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.admin-chest-rate-total.is-danger {
  color: #ff6f88;
}
.admin-chest-rate-total.is-warning {
  color: #ffc95c;
}

.live-pass-chests-panel {
  margin: 28px 0;
  padding: 26px 0;
  border-top: 1px solid rgba(69, 220, 255, .2);
  border-bottom: 1px solid rgba(235, 184, 75, .18);
}

.live-pass-chests-panel > header,
.admin-live-pass-chest-grant > header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.live-pass-chests-panel h2,
.admin-live-pass-chest-grant h4 {
  margin: 3px 0 6px;
  color: #f4f8ff;
}

.live-pass-chests-panel header p:last-child,
.admin-live-pass-chest-grant header p:last-child {
  max-width: 720px;
  margin: 0;
  color: #93a7be;
  font-size: 13px;
  line-height: 1.5;
}

.live-pass-chest-total,
.admin-live-pass-chest-grant > header > span {
  flex: 0 0 auto;
  padding: 7px 10px;
  border: 1px solid rgba(235, 184, 75, .28);
  border-radius: 6px;
  color: #ffe18d;
  background: rgba(44, 31, 9, .4);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.live-pass-chests {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.live-pass-chest-card {
  --pass-chest-accent: #f0bd4e;
  display: grid;
  grid-template-columns: minmax(190px, .72fr) minmax(230px, 1fr);
  min-height: 270px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--pass-chest-accent) 38%, transparent);
  border-radius: 8px;
  background: rgba(4, 12, 25, .94);
  box-shadow: inset 0 0 34px color-mix(in srgb, var(--pass-chest-accent) 7%, transparent);
}

.live-pass-chest-card[data-rarity="legendary"] { --pass-chest-accent: #ffb12d; }
.live-pass-chest-card[data-rarity="mythic"] { --pass-chest-accent: #ff4dd8; }
.live-pass-chest-card[data-rarity="ancestral"] { --pass-chest-accent: #49dff7; }
.live-pass-chest-card[data-rarity="divin"] { --pass-chest-accent: #ffe069; }

.live-pass-chest-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 270px;
  overflow: hidden;
  background: #020712;
}

.live-pass-chest-visual::after {
  content: "";
  position: absolute;
  right: 10%;
  bottom: 18%;
  left: 10%;
  height: 1px;
  background: var(--pass-chest-accent);
  box-shadow: 0 0 20px 7px color-mix(in srgb, var(--pass-chest-accent) 22%, transparent);
}

.live-pass-chest-visual img {
  position: relative;
  z-index: 1;
  width: min(115%, 330px);
  max-height: 270px;
  object-fit: contain;
  filter: drop-shadow(0 18px 18px rgba(0, 0, 0, .55));
  transition: transform .25s ease;
}

.live-pass-chest-card:hover .live-pass-chest-visual img { transform: translateY(-4px) scale(1.025); }

.live-pass-chest-stack {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-width: 42px;
  padding: 6px 9px;
  border: 1px solid color-mix(in srgb, var(--pass-chest-accent) 62%, transparent);
  border-radius: 6px;
  color: #fff5c8;
  background: rgba(2, 7, 18, .9);
  font-size: 13px;
  font-weight: 950;
  text-align: center;
}

.live-pass-chest-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 23px;
}

.live-pass-chest-kicker {
  color: var(--pass-chest-accent);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.live-pass-chest-copy h3 {
  margin: 0;
  color: #f7f9ff;
  font-size: 24px;
  line-height: 1.1;
}

.live-pass-chest-copy > p {
  margin: 0;
  color: #9aacc1;
  font-size: 13px;
  line-height: 1.5;
}

.live-pass-chest-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.live-pass-chest-meta span {
  padding: 5px 7px;
  border: 1px solid rgba(122, 152, 185, .18);
  border-radius: 5px;
  color: #b5c4d6;
  background: rgba(1, 7, 16, .62);
  font-size: 10px;
  font-weight: 800;
}

.live-pass-chest-meta [data-state="ready"] {
  border-color: rgba(69, 239, 191, .3);
  color: #72f0c8;
}

.live-pass-chest-actions {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 8px;
  margin-top: 2px;
}

.live-pass-chest-open {
  min-height: 44px;
  border: 1px solid color-mix(in srgb, var(--pass-chest-accent) 58%, transparent);
  border-radius: 6px;
  color: #06101d;
  background: var(--pass-chest-accent);
  font-weight: 950;
  cursor: pointer;
}

.live-pass-chest-open:disabled {
  color: #718397;
  border-color: rgba(122, 152, 185, .16);
  background: rgba(16, 29, 45, .8);
  cursor: not-allowed;
}

.live-pass-chests-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 22px;
  border: 1px dashed rgba(73, 223, 247, .24);
  color: #91a7bf;
  text-align: center;
}

.admin-live-pass-chest-grant {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid rgba(73, 223, 247, .2);
}

.admin-live-pass-chest-grant form {
  display: grid;
  grid-template-columns: 1.1fr 1.2fr .55fr 1fr auto;
  align-items: end;
  gap: 10px;
}

.admin-live-pass-chest-grant label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.admin-live-pass-chest-grant label > span {
  color: #9eafc4;
  font-size: 11px;
  font-weight: 800;
}

.admin-live-pass-chest-events {
  display: grid;
  gap: 7px;
  margin-top: 15px;
}

.admin-live-pass-chest-event {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(115, 151, 187, .12);
}

.admin-live-pass-chest-event strong,
.admin-live-pass-chest-event small { display: block; }
.admin-live-pass-chest-event strong { color: #eff5ff; font-size: 12px; }
.admin-live-pass-chest-event small,
.admin-live-pass-chest-event > span { color: #8196ad; font-size: 10px; }

@media (max-width: 1100px) {
  .live-pass-chests { grid-template-columns: 1fr; }
  .admin-live-pass-chest-grant form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1450px) {
  .admin-chest-reward-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .live-pass-chests-panel > header,
  .admin-live-pass-chest-grant > header { align-items: flex-start; flex-direction: column; }
  .live-pass-chest-card { grid-template-columns: 1fr; }
  .live-pass-chest-visual { min-height: 220px; }
  .live-pass-chest-visual img { max-height: 220px; width: min(100%, 300px); }
  .live-pass-chest-copy { padding: 18px; }
  .live-pass-chest-copy h3 { font-size: 21px; }
  .admin-live-pass-chest-grant form { grid-template-columns: 1fr; }
  .admin-live-pass-chest-event { align-items: flex-start; flex-direction: column; }
}

@keyframes shop-chest-float { 0%, 100% { transform: translateY(5px) rotate(-1deg); } 50% { transform: translateY(-9px) rotate(1deg); } }
@keyframes shop-chest-ring { 0%, 100% { opacity: .42; transform: translateX(-50%) rotateX(68deg) scale(.94); } 50% { opacity: .9; transform: translateX(-50%) rotateX(68deg) scale(1.04); } }
@keyframes shop-chest-aura { to { transform: rotate(360deg); } }
@keyframes shop-chest-reset-pulse { 50% { opacity: .45; transform: scale(.72); } }
@keyframes shop-chest-lid-open { 0% { transform: translateX(-50%) translateY(0) rotateX(0); } 55% { transform: translateX(-50%) translateY(-90px) rotateX(-40deg) scale(1.04); } 100% { transform: translateX(-50%) translateY(-170px) rotateX(-72deg) scale(.9); opacity: .12; } }
@keyframes shop-chest-base-impact { 35% { transform: translateX(-50%) translateY(12px) scale(1.04, .94); } 100% { transform: translateX(-50%) translateY(0); } }
@keyframes shop-chest-burst { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.1); box-shadow: 0 0 0 0 #fff; } 25% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) scale(18); box-shadow: 0 0 180px 70px #2dcfff, 0 0 300px 140px #7754ff; } }
@keyframes shop-chest-copy-in { to { opacity: 1; transform: translateY(0); } }

@media (max-width: 1120px) {
  .shop-chest-grid { grid-template-columns: 1fr; }
  .admin-chest-builder { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-chest-reward-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .shop-chest-section { margin-inline: -4px; padding: 15px; border-radius: 18px; }
  .shop-chest-heading { align-items: flex-start; flex-direction: column; }
  .shop-chest-reset { white-space: normal; }
  .shop-chest-card { grid-template-columns: 1fr; }
  .shop-chest-visual { min-height: 230px; }
  .shop-chest-image { max-height: 230px; width: min(90%, 290px); }
  .shop-chest-copy { padding: 5px 18px 20px; }
  .shop-chest-copy > p { min-height: 0; }
  .shop-chest-dialog { padding: 21px 15px 16px; }
  .shop-chest-odds-row { grid-template-columns: 68px minmax(0, 1fr); }
  .shop-chest-odds-rate { grid-column: 2; }
  .shop-chest-dialog footer { align-items: stretch; flex-direction: column; }
  .shop-chest-opening-modal { padding: 4px; }
  .shop-chest-opening-dialog {
    width: calc(100vw - 8px);
    height: calc(100dvh - 8px);
    min-height: 0;
    grid-template-rows: auto minmax(185px, 1fr) minmax(145px, .72fr) auto;
    padding: 34px 14px 16px;
    background-position: 50% 50%;
  }
  .shop-chest-opening-header .eyebrow { letter-spacing: 4px; }
  .shop-chest-opening-header h2 { font-size: clamp(25px, 8vw, 36px); }
  .shop-chest-opening-divider { width: 86%; margin-top: 4px; }
  .shop-chest-opening-rewards {
    width: calc(100% + 4px);
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(205px, 72vw);
    justify-content: start;
    gap: 13px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 10px 8vw 14px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .shop-chest-opening-rewards::-webkit-scrollbar { display: none; }
  .shop-chest-opening-rewards .shop-chest-result {
    min-height: 178px;
    padding: 14px 11px;
    scroll-snap-align: center;
  }
  .shop-chest-opening-rewards .shop-chest-reward-icon,
  .shop-chest-opening-rewards .shop-chest-reward-icon.is-frame-preview { width: 96px; height: 96px; }
  .shop-chest-opening-stage { min-height: 145px; }
  .shop-chest-opening-image { width: min(330px, 78vw); max-height: 180px; }
  .shop-chest-opening-footer { gap: 4px; }
  .shop-chest-claim { min-height: 58px; }
  .shop-chest-jackpots > header { align-items: flex-start; flex-direction: column; }
  .shop-chest-jackpot-card { grid-template-columns: 48px minmax(0, 1fr); }
  .shop-chest-jackpot-reward { grid-column: 1 / -1; }
  .admin-chest-builder,
  .admin-chest-reward-row { grid-template-columns: 1fr; }
  .admin-chest-reward-row .wide,
  .admin-chest-reward-row .reward-reference { grid-column: auto; }
  .admin-chest-reward-editor > header,
  .admin-chest-actions { align-items: stretch; flex-direction: column; }
  .admin-chest-reward-actions { align-items: stretch; flex-direction: column; }
  .admin-chest-card { grid-template-columns: 90px minmax(0, 1fr); }
  .admin-chest-card > img { width: 90px; height: 90px; }
}

@media (prefers-reduced-motion: reduce) {
  .shop-chest-card::before,
  .shop-chest-image,
  .shop-chest-visual::before,
  .shop-chest-visual::after,
  .shop-chest-reset i { animation: none !important; }
  .shop-chest-opening-modal.is-opening .shop-chest-opening-image,
  .shop-chest-opening-modal.is-revealed .shop-chest-opening-image,
  .shop-chest-opening-modal.is-opening .shop-chest-burst,
  .shop-chest-opening-modal.is-revealed .shop-chest-result,
  .shop-chest-opening-particles,
  .shop-chest-opening-rays { animation-duration: .01ms !important; animation-delay: 0s !important; }
}
