

.cc-live-ref,
.store-shop-panel,
.inventory-panel {
  --primary: #ffa500;
  --accent: #ffd700;
  --accent-glow: rgba(255, 215, 0, 0.55);
  --free-coin: #4fc3f7;
  --text: #f6f7f9;
  --muted-text: #858e99;
  --danger: #ff665b;
  --surface-elevated: #121820;
  --card-border: rgba(255, 255, 255, 0.12);
  --rarity-common: #9ba1a6;
  --rarity-rare: #29b6f6;
  --rarity-epic: #aa00ff;
  --rarity-legendary: #ffd700;
  --trans-fast: 150ms ease;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
}

/* ── Shop grid + item cards (live SHOP tab DNA) ── */

.cc-live-ref .inventory-grid,
.store-shop-panel .inventory-grid,
.inventory-panel .inventory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  grid-auto-rows: min-content;
  gap: 10px;
  overflow-y: auto;
  padding-right: 6px;
  align-content: start;
  position: relative;
  min-height: 0;
  flex: 1;
}

.cc-live-ref .inventory-grid {
  max-height: min(70vh, 560px);
  padding: 12px;
  border: 1px solid var(--card-border);
  border-radius: 8px;
  background: #0a0e13;
}

.cc-live-ref .inventory-grid::-webkit-scrollbar,
.store-shop-panel .inventory-grid::-webkit-scrollbar,
.inventory-panel .inventory-grid::-webkit-scrollbar{
  width: 6px;
}
.cc-live-ref .inventory-grid::-webkit-scrollbar-thumb,
.store-shop-panel .inventory-grid::-webkit-scrollbar-thumb,
.inventory-panel .inventory-grid::-webkit-scrollbar-thumb{
  background: rgba(255, 165, 0, 0.5);
  border-radius: 3px;
}

.cc-live-ref .inventory-item,
.store-shop-panel .inventory-item,
.inventory-panel .inventory-item{
  position: relative;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: auto;
  min-height: 0;
  padding: 6px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-top-width: 2px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.03);
  overflow: hidden;
  transition: var(--trans-fast);
  cursor: pointer;
}

.cc-live-ref .inventory-item:hover,
.store-shop-panel .inventory-item:hover,
.inventory-panel .inventory-item:hover{
  transform: translateY(-2px);
  border-color: rgba(255, 165, 0, 0.45);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.cc-live-ref .inventory-item.is-selected,
.store-shop-panel .inventory-item.is-selected,
.inventory-panel .inventory-item.is-selected{
  border-color: rgba(255, 165, 0, 0.55);
  background: rgba(255, 165, 0, 0.08);
}

.cc-live-ref .inventory-item.rarity-common,
.store-shop-panel .inventory-item.rarity-common,
.inventory-panel .inventory-item.rarity-common{ border-top-color: var(--rarity-common); }
.cc-live-ref .inventory-item.rarity-rare,
.store-shop-panel .inventory-item.rarity-rare,
.inventory-panel .inventory-item.rarity-rare{ border-top-color: var(--rarity-rare); }
.cc-live-ref .inventory-item.rarity-epic,
.store-shop-panel .inventory-item.rarity-epic,
.inventory-panel .inventory-item.rarity-epic{ border-top-color: var(--rarity-epic); }
.cc-live-ref .inventory-item.rarity-legendary,
.store-shop-panel .inventory-item.rarity-legendary,
.inventory-panel .inventory-item.rarity-legendary{
  border-top-color: var(--rarity-legendary);
  box-shadow: 0 0 8px rgba(255, 215, 0, 0.1);
}

.cc-live-ref .item-type-icon,
.store-shop-panel .item-type-icon,
.inventory-panel .item-type-icon{
  position: absolute;
  top: 4px;
  left: 4px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.6);
  color: var(--text);
  font-size: 8px;
}

.cc-live-ref .item-preview,
.store-shop-panel .item-preview,
.inventory-panel .item-preview{
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  height: auto;
  border-radius: 4px;
  background: radial-gradient(circle, #444 0%, #222 100%);
  position: relative;
}

.cc-live-ref .item-preview i.main-icon,
.store-shop-panel .item-preview i.main-icon,
.inventory-panel .item-preview i.main-icon{
  font-size: 28px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.cc-live-ref .item-preview .preview-emoji,
.store-shop-panel .item-preview .preview-emoji,
.inventory-panel .item-preview .preview-emoji{
  font-size: 28px;
  line-height: 1;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.cc-live-ref .item-info,
.store-shop-panel .item-info,
.inventory-panel .item-info{
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.cc-live-ref .item-name,
.store-shop-panel .item-name,
.inventory-panel .item-name{
  color: var(--text);
  font-size: 10px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cc-live-ref .item-btn,
.store-shop-panel .item-btn,
.inventory-panel .item-btn{
  width: 100%;
  padding: 4px;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  transition: var(--trans-fast);
}

.cc-live-ref .item-btn.equipped,
.store-shop-panel .item-btn.equipped,
.inventory-panel .item-btn.equipped{
  border: 1px solid var(--primary);
  background: rgba(255, 165, 0, 0.2);
  color: var(--primary);
  cursor: default;
}

.cc-live-ref .item-btn.purchase,
.store-shop-panel .item-btn.purchase,
.inventory-panel .item-btn.purchase{
  border: 1px solid rgba(255, 165, 0, 0.4);
  background: transparent;
  color: var(--primary);
  box-shadow: inset 0 0 0 1px transparent;
}

.cc-live-ref .item-btn.purchase:hover:not(:disabled),
.store-shop-panel .item-btn.purchase:hover:not(:disabled),
.inventory-panel .item-btn.purchase:hover:not(:disabled){
  border-color: var(--primary);
  background: rgba(255, 165, 0, 0.08);
  color: #fff;
  box-shadow: 0 0 12px rgba(255, 165, 0, 0.2);
}

.cc-live-ref .btn-price-icon-coins,
.store-shop-panel .btn-price-icon-coins,
.inventory-panel .btn-price-icon-coins{
  color: var(--accent);
  margin-right: 3px;
}

/* ── Coin packages (live top-up strip DNA) ── */

.cc-live-ref .cc-topup-section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cc-live-ref .cc-topup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.cc-live-ref .cc-topup-title {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: Rajdhani, sans-serif;
  font-weight: 900;
  font-size: 18px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.cc-live-ref .cc-topup-title i { color: var(--accent); }

.cc-live-ref .cc-topup-subtitle {
  margin: 0;
  color: var(--muted-text);
  font-size: 12px;
}

.cc-live-ref .cc-coin-packages {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
}

.cc-live-ref .cc-coin-package-card {
  position: relative;
  padding: 14px 14px 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(0, 0, 0, 0.15) 100%);
  text-align: center;
  transition: var(--trans-fast);
}

.cc-live-ref .cc-coin-package-card:hover {
  border-color: rgba(255, 165, 0, 0.35);
  transform: translateY(-2px);
}

.cc-live-ref .cc-coin-package-card.is-featured {
  border-color: rgba(255, 215, 0, 0.55);
  box-shadow: 0 0 26px rgba(255, 215, 0, 0.08);
}

.cc-live-ref .cc-coin-package-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 10px;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 999px;
  background: rgba(255, 165, 0, 0.95);
  color: #1b1300;
  font-family: Rajdhani, sans-serif;
  font-weight: 900;
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.cc-live-ref .cc-coin-package-icon {
  margin: 6px 0 10px;
  color: var(--accent);
  font-size: 28px;
  filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.25));
}

.cc-live-ref .cc-coin-package-amount {
  margin: 0 0 2px;
  font-family: Rajdhani, sans-serif;
  font-weight: 900;
  font-size: 22px;
  letter-spacing: 0.5px;
}

.cc-live-ref .cc-coin-package-bonus {
  height: 16px;
  margin-bottom: 10px;
  color: rgba(76, 175, 80, 0.95);
  font-size: 11px;
  font-weight: 700;
}

.cc-live-ref .cc-coin-package-btn {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(255, 165, 0, 0.95);
  color: #1b1300;
  cursor: pointer;
  font-family: Rajdhani, sans-serif;
  font-weight: 900;
  font-size: 14px;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: var(--trans-fast);
}

.cc-live-ref .cc-coin-package-btn:hover:not(:disabled) {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.cc-live-ref .cc-coin-package-meta {
  margin-top: 8px;
  color: var(--muted-text);
  font-size: 11px;
}

/* ── Stripe sheet (live chrome; live Payment Element slot) ── */

.cc-stripe-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 14000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
}

.cc-stripe-modal-backdrop.is-open {
  display: flex;
}

.cc-stripe-modal {
  width: min(500px, 94vw);
  padding: 16px;
  border: 1px solid var(--card-border, rgba(255, 255, 255, 0.12));
  border-radius: 14px;
  background: var(--surface-elevated, #121820);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
}

.cc-stripe-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.cc-stripe-modal-header h3 {
  margin: 0;
  font-family: Rajdhani, sans-serif;
  font-size: 21px;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.cc-stripe-desc {
  margin-bottom: 8px;
  color: var(--muted-text, #858e99);
  font-size: 12px;
  line-height: 1.4;
}

.cc-stripe-payment-element {
  margin: 10px 0 6px;
  min-height: 72px;
  padding: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: var(--muted-text, #858e99);
  font-size: 12px;
}

.cc-stripe-error {
  margin-top: 8px;
  color: var(--danger, #ff665b);
  font-size: 12px;
}

.cc-stripe-status {
  margin-top: 8px;
  color: var(--muted-text, #858e99);
  font-size: 12px;
}

.cc-stripe-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 12px;
}

.cc-stripe-actions .btn {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  cursor: pointer;
  font-family: Rajdhani, sans-serif;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.cc-stripe-actions .btn-muted {
  background: rgba(255, 255, 255, 0.06);
  color: #cfd4da;
}

.cc-stripe-actions .btn-accent {
  border-color: rgba(255, 165, 0, 0.45);
  background: rgba(255, 165, 0, 0.95);
  color: #1b1300;
}

/* ── Top-up juice (global class names — match live JS) ── */

.cc-topup-shockwave {
  position: fixed;
  border-radius: 50%;
  border: 4px solid var(--accent, #ffd700);
  transform: translate(-50%, -50%) scale(0);
  opacity: 1;
  pointer-events: none;
  z-index: 15000;
  box-shadow: 0 0 20px var(--accent, #ffd700), inset 0 0 20px var(--accent, #ffd700);
  animation: ccTopupShockwaveExpand 0.6s ease-out forwards;
}

@keyframes ccTopupShockwaveExpand {
  0% { transform: translate(-50%, -50%) scale(0); opacity: 1; border-width: 10px; }
  100% { transform: translate(-50%, -50%) scale(3); opacity: 0; border-width: 0; }
}

.cc-topup-sparkle {
  position: fixed;
  width: 4px;
  height: 4px;
  background: #fff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 14999;
  animation: ccTopupSparkleFade 0.5s linear forwards;
}

@keyframes ccTopupSparkleFade {
  0% { transform: scale(1); opacity: 1; }
  100% { transform: scale(0); opacity: 0; }
}

.cc-topup-flying-coin,
.cc-topup-flying-tag {
  position: fixed;
  font-size: 24px;
  pointer-events: none;
  z-index: 15001;
}

.cc-topup-flying-coin {
  color: var(--accent, #ffd700);
  filter: drop-shadow(0 0 10px var(--accent-glow, rgba(255, 215, 0, 0.55)));
}

.cc-topup-flying-tag {
  color: var(--cyan, #39aef2);
  filter: drop-shadow(0 0 10px rgba(var(--cyan-rgb, 57, 174, 242), 0.55));
}

.cc-balance-bump {
  display: inline-block;
  color: var(--accent, #ffd700);
  text-shadow: 0 0 10px var(--accent, #ffd700);
  transform: scale(1.1);
  transition: all 0.05s;
}

.resource--coins.cc-receiving,
.currency-badge.cc-receiving {
  border-color: rgba(255, 215, 0, 0.7) !important;
  box-shadow: 0 0 30px var(--accent-glow, rgba(255, 215, 0, 0.55));
  transform: scale(1.05);
}

.resource--tags.cc-receiving {
  border-color: rgba(var(--cyan-rgb, 57, 174, 242), 0.7);
  box-shadow: 0 0 30px rgba(var(--cyan-rgb, 57, 174, 242), 0.45);
  transform: scale(1.05);
}

/* ── Purchase reveal overlay (shop tab juice) ── */

.cc-live-ref .purchase-overlay,
.store-shop-panel .purchase-overlay,
.inventory-panel .purchase-overlay{
  position: absolute;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cc-live-ref .purchase-overlay.active,
.store-shop-panel .purchase-overlay.active,
.inventory-panel .purchase-overlay.active{
  opacity: 1;
  pointer-events: all;
}

.cc-live-ref .purchase-reveal-box,
.store-shop-panel .purchase-reveal-box,
.inventory-panel .purchase-reveal-box{
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 0;
  transform: scale(0.5) translateY(-50px);
}

.cc-live-ref .purchase-overlay.tier-common.active .purchase-reveal-box,
.store-shop-panel .purchase-overlay.tier-common.active .purchase-reveal-box,
.inventory-panel .purchase-overlay.tier-common.active .purchase-reveal-box{
  animation: ccDropCommon 0.4s ease-out forwards;
  animation-delay: 0.1s;
}
.cc-live-ref .purchase-overlay.tier-rare.active .purchase-reveal-box,
.store-shop-panel .purchase-overlay.tier-rare.active .purchase-reveal-box,
.inventory-panel .purchase-overlay.tier-rare.active .purchase-reveal-box{
  animation: ccDropRare 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.1s;
}
.cc-live-ref .purchase-overlay.tier-epic.active .purchase-reveal-box,
.store-shop-panel .purchase-overlay.tier-epic.active .purchase-reveal-box,
.inventory-panel .purchase-overlay.tier-epic.active .purchase-reveal-box{
  animation: ccDropEpic 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.1s;
}
.cc-live-ref .purchase-overlay.tier-legendary.active .purchase-reveal-box,
.store-shop-panel .purchase-overlay.tier-legendary.active .purchase-reveal-box,
.inventory-panel .purchase-overlay.tier-legendary.active .purchase-reveal-box{
  animation: ccDropLegendary 0.9s cubic-bezier(0.5, 0, 0.2, 1) forwards;
  animation-delay: 0.1s;
}

@keyframes ccDropCommon {
  0% { transform: translateY(20px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}
@keyframes ccDropRare {
  0% { transform: scale(0.8) translateY(-50px); opacity: 0; }
  60% { transform: scale(1.05) translateY(5px); opacity: 1; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}
@keyframes ccDropEpic {
  0% { transform: scale(0.5) translateY(-100px); opacity: 0; }
  50% { transform: scale(1.1) translateY(10px); opacity: 1; }
  70% { transform: scale(0.95) translateY(-5px); }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}
@keyframes ccDropLegendary {
  0% { transform: scale(0.1) translateY(-200px) rotate(-10deg); opacity: 0; }
  40% { transform: scale(1.2) translateY(20px) rotate(5deg); opacity: 1; }
  55% { transform: scale(0.9) translateY(-10px) rotate(-2deg); }
  75% { transform: scale(1.05) translateY(2px) rotate(1deg); }
  100% { transform: scale(1) translateY(0) rotate(0deg); opacity: 1; }
}

/* Glow — escalates by tier (live character-customization.css) */
.cc-live-ref .reveal-glow,
.store-shop-panel .reveal-glow,
.inventory-panel .reveal-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 0;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--reward-color, #fff) 0%, transparent 70%);
  opacity: 0.3;
  filter: blur(15px);
  transform: translate(-50%, -50%);
  animation: ccPulseGlow 4s infinite alternate;
}

.cc-live-ref .purchase-overlay.tier-epic .reveal-glow,
.store-shop-panel .purchase-overlay.tier-epic .reveal-glow,
.inventory-panel .purchase-overlay.tier-epic .reveal-glow {
  width: 250px;
  height: 250px;
  opacity: 0.5;
  animation: ccPulseGlowEpic 3s infinite alternate;
}

.cc-live-ref .purchase-overlay.tier-legendary .reveal-glow,
.store-shop-panel .purchase-overlay.tier-legendary .reveal-glow,
.inventory-panel .purchase-overlay.tier-legendary .reveal-glow {
  width: 400px;
  height: 400px;
  opacity: 0.7;
  background: radial-gradient(circle, #ffd700 0%, #ff4500 40%, transparent 70%);
  animation: ccPulseGlowLegendary 2.5s infinite alternate;
}

@keyframes ccPulseGlow {
  from { opacity: 0.2; transform: translate(-50%, -50%) scale(0.9); }
  to { opacity: 0.4; transform: translate(-50%, -50%) scale(1.1); }
}
@keyframes ccPulseGlowEpic {
  from { opacity: 0.3; transform: translate(-50%, -50%) scale(0.95); }
  to { opacity: 0.5; transform: translate(-50%, -50%) scale(1.15); }
}
@keyframes ccPulseGlowLegendary {
  from { opacity: 0.4; transform: translate(-50%, -50%) scale(0.95) rotate(0deg); }
  to { opacity: 0.7; transform: translate(-50%, -50%) scale(1.15) rotate(5deg); }
}

/* Rounded icon tile — ref/live extract only. Store Mode reuses .spin-card--hero. */
.cc-live-ref .reveal-icon-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  overflow: hidden;
  border: 2px solid var(--reward-color, #fff);
  border-radius: 8px;
  background: var(--surface-elevated, #121820);
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5), inset 0 0 15px rgba(0, 0, 0, 0.5);
  font-size: 36px;
  line-height: 1;
}

.cc-live-ref .reveal-icon-wrapper i {
  color: var(--reward-color, #fff);
  font-size: 42px;
  filter: drop-shadow(0 0 8px var(--reward-color, #fff));
}

/* Screen flash — epic / legendary only */
.cc-live-ref .flash-overlay,
.store-shop-panel .flash-overlay,
.inventory-panel .flash-overlay {
  position: absolute;
  z-index: 10;
  inset: 0;
  background: #fff;
  opacity: 0;
  pointer-events: none;
}

.cc-live-ref .purchase-overlay.tier-epic.active .flash-overlay,
.store-shop-panel .purchase-overlay.tier-epic.active .flash-overlay,
.inventory-panel .purchase-overlay.tier-epic.active .flash-overlay {
  animation: ccFlashEpic 0.8s ease-out forwards;
  animation-delay: 0.4s;
}

.cc-live-ref .purchase-overlay.tier-legendary.active .flash-overlay,
.store-shop-panel .purchase-overlay.tier-legendary.active .flash-overlay,
.inventory-panel .purchase-overlay.tier-legendary.active .flash-overlay {
  animation: ccFlashLegendary 1.2s ease-out forwards;
  animation-delay: 0.45s;
}

@keyframes ccFlashEpic {
  0% { opacity: 0; background: #fff; }
  10% { opacity: 0.8; background: #aa00ff; }
  100% { opacity: 0; }
}
@keyframes ccFlashLegendary {
  0% { opacity: 0; background: #fff; }
  15% { opacity: 1; background: #ffd700; }
  100% { opacity: 0; }
}

/* Legendary rays — hidden until tier-legendary */
.cc-live-ref .legendary-rays,
.store-shop-panel .legendary-rays,
.inventory-panel .legendary-rays {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 0;
  display: none;
  width: 200vmax;
  height: 200vmax;
  background: repeating-conic-gradient(
    from 0deg,
    rgba(255, 215, 0, 0.08) 0deg 5deg,
    transparent 5deg 15deg
  );
  transform: translate(-50%, -50%);
  animation: ccSpinRays 60s linear infinite;
  pointer-events: none;
}

.cc-live-ref .purchase-overlay.tier-legendary .legendary-rays,
.store-shop-panel .purchase-overlay.tier-legendary .legendary-rays,
.inventory-panel .purchase-overlay.tier-legendary .legendary-rays {
  display: block;
}

@keyframes ccSpinRays {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.cc-live-ref .reveal-info,
.store-shop-panel .reveal-info,
.inventory-panel .reveal-info {
  z-index: 1;
  margin-top: 16px;
  text-align: center;
}

.cc-live-ref .reveal-rarity,
.store-shop-panel .reveal-rarity,
.inventory-panel .reveal-rarity {
  margin-bottom: 4px;
  color: var(--reward-color, #fff);
  font-family: Rajdhani, sans-serif;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0;
}

.cc-live-ref .reveal-name,
.store-shop-panel .reveal-name,
.inventory-panel .reveal-name {
  margin: 0;
  color: #fff;
  font-family: Rajdhani, sans-serif;
  font-size: 24px;
  font-weight: 800;
  text-transform: uppercase;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  opacity: 0;
}

.cc-live-ref .purchase-overlay.active .reveal-rarity,
.store-shop-panel .purchase-overlay.active .reveal-rarity,
.inventory-panel .purchase-overlay.active .reveal-rarity {
  animation: ccSlideUpFade 0.4s forwards 0.4s;
}

.cc-live-ref .purchase-overlay.active .reveal-name,
.store-shop-panel .purchase-overlay.active .reveal-name,
.inventory-panel .purchase-overlay.active .reveal-name {
  animation: ccSlideUpFade 0.4s forwards 0.5s;
}

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

.cc-live-ref .reveal-actions,
.store-shop-panel .reveal-actions,
.inventory-panel .reveal-actions {
  z-index: 1;
  display: flex;
  gap: 10px;
  margin-top: 24px;
  opacity: 0;
}

.cc-live-ref .purchase-overlay.active .reveal-actions,
.store-shop-panel .purchase-overlay.active .reveal-actions,
.inventory-panel .purchase-overlay.active .reveal-actions {
  animation: ccSlideUpFade 0.4s forwards 0.6s;
}

/* Rounded live buttons — ref extract only. Store Mode reuses .shop-buy-btn. */
.cc-live-ref .btn-equip-reveal {
  padding: 8px 22px;
  border: 0;
  border-radius: 6px;
  background: #fff;
  color: #000;
  cursor: pointer;
  font-family: Rajdhani, sans-serif;
  font-size: 14px;
  font-weight: 900;
  text-transform: uppercase;
  transition: background 150ms ease, transform 150ms ease;
}

.cc-live-ref .btn-equip-reveal:hover {
  background: #e0e0e0;
  transform: scale(1.04);
}

.cc-live-ref .btn-continue-reveal {
  padding: 8px 16px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  font-family: Rajdhani, sans-serif;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  transition: border-color 150ms ease, color 150ms ease;
}

.cc-live-ref .btn-continue-reveal:hover {
  border-color: #fff;
  color: #fff;
}

/* Confetti — count/spread set by JS per rarity */
.cc-live-ref .confetti-container,
.store-shop-panel .confetti-container,
.inventory-panel .confetti-container {
  position: absolute;
  z-index: 50;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.cc-live-ref .confetti,
.store-shop-panel .confetti,
.inventory-panel .confetti {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  background: var(--reward-color, #fff);
  opacity: 0;
}

.cc-live-ref .purchase-overlay.active .confetti,
.store-shop-panel .purchase-overlay.active .confetti,
.inventory-panel .purchase-overlay.active .confetti {
  animation: ccPopConfetti 1s ease-out forwards;
}

@keyframes ccPopConfetti {
  0% { opacity: 1; transform: translate(0, 0) scale(1) rotate(0deg); }
  100% {
    opacity: 0;
    transform: translate(var(--tx), var(--ty)) scale(0) rotate(var(--rot));
  }
}

/* Ref page chrome only */
.cc-live-ref {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}

.cc-live-ref__tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.cc-live-ref__tab {
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  background: transparent;
  color: #858e99;
  font-family: Rajdhani, sans-serif;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cc-live-ref__tab.is-active {
  border-color: #fff;
  color: #ffa500;
}

.cc-live-ref__note {
  margin: 0 0 16px;
  color: #858e99;
  font-size: 13px;
  line-height: 1.45;
}

.cc-live-ref__wallet {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 215, 0, 0.35);
  border-radius: 6px;
  background: #0c1015;
}
