:root {
  --bg-color: #1e293b;
  --panel-bg: rgba(11, 20, 49, 0.8);
  --border-color: rgba(30, 45, 92, 0.5);
  --text-main: #f8fafc;
  --text-muted: #ffffff;
  --accent-yellow: #ffffff;
  --accent-blue: #3b82f6;
  --accent-green: #00e676;
  --accent-cyan: #00e5ff;
  --accent-purple: #9333ea;
  --bg-gradient-angle: 180deg;
  --bg-gradient-start: #1b2735;
  --bg-gradient-end: #090a0f;
  --bg-glow-x: 43%;
  --bg-glow-y: 73%;
  --bg-horizon-glow-opacity: 0.16;
  --bg-glow-opacity: 0.08;
  --star-start-y: 100px;
  --star-end-y: -2970px;
  --star-speed-mult: 1.05;
  --star-opacity-mult: 1;
  --star-density-mult: 1;
  --starfield-glow-opacity: 0.8;
  
  /* UI Layout Variables */
  --hud-top: 18px;
  --hud-left: 18px;
  --dev-bottom: 9px;
  --dev-left: 24px;
  --sidebar-width: 381px;
  --app-padding-left: 170px;
  --app-gap: 0px;
  --font-family-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-scale: 1;
  --hud-stack-gap: 10px;
  --hud-top-row-gap: 10px;
  --hud-stats-gap: 24px;
  --bucket-body-top-color: #2563eb;
  --bucket-body-bottom-color: #1e3a8a;
  --bucket-border-color: rgba(255, 255, 255, 0.3);
  --bucket-inner-color: rgba(0, 0, 0, 0.3);
  --bucket-border-radius: 12px;
  --bucket-value-color: #ffffff;
  --bucket-value-font-size: 20px;
  --bucket-value-pad-x: 12px;
  --bucket-value-y: 46px;
  --bucket-badge-bg: rgba(0, 0, 0, 0.45);
  --bucket-badge-color: #ffffff;
  --bucket-badge-radius: 6px;
  --bucket-badge-width: 58px;
  --bucket-badge-height: 18px;
  --bucket-badge-pad-x: 10px;
  --bucket-badge-font-size: 12px;
  --bucket-badge-value-x: 16px;
  --bucket-badge-value-y: -5px;
  --bucket-level-color: rgba(255, 255, 255, 0.8);
  --bucket-level-font-size: 16px;
  --bucket-level-pad-right: 12px;
  --bucket-level-y: 46px;
  --bucket-exp-bg: rgba(0, 0, 0, 0.4);
  --bucket-exp-pad: 12px;
  --bucket-exp-height: 10px;
  --bucket-exp-y: 20px;
  --bucket-exp-radius: 5px;
  --bucket-exp-start: #4ade80;
  --bucket-exp-end: #22c55e;
  --bucket-inner-height: 20px;
  --bucket-inner-radius: 6px;
  --skin-meta-justify: center;
  --skin-status-font-family: var(--font-family-main);
  --skin-status-font-size: 1rem;
  --skin-status-font-weight: 800;
  --skin-status-letter-spacing: 0.05em;
  --skin-status-line-height: 1.1;
  --skin-status-text-align: center;
  --skin-status-transform: uppercase;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
}

body {
  position: relative;
  font-family: var(--font-family-main);
  font-size: calc(16px * var(--font-scale));
  background-color: var(--bg-color);
  color: var(--text-main);
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(circle at var(--bg-glow-x, 50%) var(--bg-glow-y, 84%), rgba(59, 130, 246, var(--bg-horizon-glow-opacity, 0.16)), transparent 34%),
    radial-gradient(circle at var(--bg-glow-x, 50%) var(--bg-glow-y, 84%), rgba(34, 211, 238, var(--bg-glow-opacity, 0.08)), transparent 24%),
    linear-gradient(var(--bg-gradient-angle), var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
}

.star-layer {
  position: absolute;
  top: 0;
  left: 0;
  background: transparent;
  width: var(--star-size, 1px);
  height: var(--star-size, 1px);
  box-shadow: var(--star-shadows, none);
  opacity: calc(var(--star-opacity, 1) * var(--star-opacity-mult, 1));
  animation: animStar calc(var(--star-duration, 50s) * var(--star-speed-mult, 1)) linear infinite;
  will-change: transform;
}

.star-layer::after {
  content: "";
  position: absolute;
  top: 2000px;
  left: 0;
  width: var(--star-size, 1px);
  height: var(--star-size, 1px);
  background: transparent;
  box-shadow: var(--star-shadows, none);
}

#stars {
  --star-size: 1px;
  --star-duration: 50s;
  --star-opacity: 0.95;
  --star-start-y: 100px;
  --star-end-y: -2970px;
  --star-speed-mult: 1.05;
}

#stars2 {
  --star-size: 2px;
  --star-duration: 100s;
  --star-opacity: 0.85;
  --star-start-y: 100px;
  --star-end-y: -2970px;
  --star-speed-mult: 1.05;
}

#stars3 {
  --star-size: 3px;
  --star-duration: 150s;
  --star-opacity: 0.75;
  --star-start-y: 100px;
  --star-end-y: -2970px;
  --star-speed-mult: 1.05;
}

.starfield-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at var(--bg-glow-x, 50%) var(--bg-glow-y, 84%), rgba(59, 130, 246, 0.14), transparent 32%),
    radial-gradient(circle at var(--bg-glow-x, 50%) var(--bg-glow-y, 84%), rgba(34, 211, 238, 0.08), transparent 22%);
  mix-blend-mode: screen;
  opacity: var(--starfield-glow-opacity, 0.8);
}

@keyframes animStar {
  from {
    transform: translateY(var(--star-start-y, 100px));
  }

  to {
    transform: translateY(var(--star-end-y, -2970px));
  }
}

/* UI Scale Wrapper */
#ui-scale-root {
  position: fixed;
  top: 0;
  left: 0;
  width: 1366px;
  height: 768px;
  transform-origin: top left;
  z-index: 1;
  /* transform is set dynamically by JS */
}

#app {
  display: flex;
  width: 1366px;
  height: 768px;
  padding: 24px 24px 24px var(--app-padding-left);
  gap: var(--app-gap);
  position: relative;
}

/* HUD (Top-Left) */
.hud {
  position: absolute;
  top: var(--hud-top);
  left: var(--hud-left);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: var(--hud-stack-gap);
  min-width: 320px;
  padding: 10px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.hud-top-row {
  display: flex;
  align-items: center;
  gap: var(--hud-top-row-gap);
}

.hud .level-container {
  margin-bottom: 0;
  flex: 1;
  min-width: 0;
}

.hud-star-balance {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0;
  margin-left: 4px;
  background: transparent;
  border: none;
}

.hud-stats {
  display: flex;
  justify-content: space-between;
  gap: var(--hud-stats-gap);
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.stat-value-score {
  font-size: 2.25rem;
  font-weight: 900;
  color: var(--accent-yellow);
  line-height: 1;
}

.stat-value-balls {
  font-size: 2rem;
  font-weight: 900;
  color: white;
  line-height: 1;
}

.stat-value-income {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--accent-green);
  line-height: 1;
}

.hud-star-icon {
  width: 30px;
  height: 30px;
  display: block;
  flex: 0 0 auto;
}

.stat-value-star {
  font-size: 2.00rem;
  font-weight: 900;
  color: #fde68a;
  text-shadow: 0 0 10px rgba(251, 191, 36, 0.25);
  min-width: 24px;
  text-align: right;
}

.sub-stats {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hud-income-box, .hud-balls-box {
  display: flex;
  flex-direction: column;
}

/* Plinko Board Container */
.board-container {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: crosshair;
}

.board-container canvas {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  aspect-ratio: 1 / 1;
}

/* ---- FIRST DROP HINT ---- */
#first-drop-hint {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 10;
  animation: hint-float 1.2s ease-in-out infinite;
}

#first-drop-hint .hint-arrow {
  width: 0;
  height: 0;
  border-left: 14px solid transparent;
  border-right: 14px solid transparent;
  border-top: 20px solid #ffd800;
  filter: drop-shadow(0 0 8px #ffd800aa);
}

#first-drop-hint .hint-text {
  font-size: 0.75rem;
  font-weight: 800;
  color: #ffd800;
  text-shadow: 0 0 10px #ffd800aa;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

#first-drop-hint.hidden { display: none; }

@keyframes hint-float {
  0%, 100% { transform: translate(-50%, -60%); opacity: 1; }
  50%       { transform: translate(-50%, -50%); opacity: 0.7; }
}

/* Sidebar */
.sidebar {
  width: var(--sidebar-width);
  height: 720px;
  display: flex;
  flex-direction: column;
  overflow: visible; /* Changed from hidden to allow shadow/glow if needed */
}

/* Tab Navigation */
.tab-nav {
  display: flex;
  justify-content: space-between;
  background: transparent;
  padding: 12px 0;
  gap: 8px;
  position: relative;
  z-index: 10;
}

.tab-btn {
  flex: 1;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.08), rgba(15, 23, 42, 0.62));
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(226, 232, 240, 0.84);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  cursor: pointer;
  border-radius: 12px;
  transition: all 0.1s;
  z-index: 2;
  min-height: 54px;
  position: relative;
  overflow: visible;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 4px 0 rgba(0, 0, 0, 0.3);
}

.tab-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  transition: transform 0.2s;
  opacity: 0.88;
}

.tab-btn.active .tab-icon {
  transform: scale(1.15);
  opacity: 1;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
}

.tab-btn:hover:not(.active) {
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.12), rgba(30, 41, 59, 0.72));
  color: white;
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 5px 0 rgba(0, 0, 0, 0.3);
}

.tab-btn.active {
  color: white;
  transform: translateY(2px);
}

.tab-alert-badge {
  position: absolute;
  top: -6px;
  right: -4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to bottom, #ff6b6b, #dc2626);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 900;
  line-height: 1;
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.95), 0 8px 16px rgba(220, 38, 38, 0.45);
  pointer-events: none;
  transform-origin: 50% 60%;
  animation: tabBadgePulse 1.15s ease-in-out infinite;
}

.tab-alert-badge.hidden {
  display: none;
}

@keyframes tabBadgePulse {
  0%, 100% {
    transform: scale(1) rotate(0deg);
    filter: drop-shadow(0 0 0 rgba(255, 99, 99, 0));
  }
  35% {
    transform: scale(1.12) rotate(-10deg);
    filter: drop-shadow(0 0 10px rgba(255, 99, 99, 0.55));
  }
  70% {
    transform: scale(0.98) rotate(10deg);
    filter: drop-shadow(0 0 14px rgba(255, 99, 99, 0.7));
  }
}

/* Active Colors per Tab with 3D Shadows */
.tab-btn[data-tab="upgrades"].active { 
  background: linear-gradient(to bottom, #2563eb, #1d4ed8); 
  box-shadow: 0 2px 0 #1e3a8a !important; 
}
.tab-btn[data-tab="prestige"].active { 
  background: linear-gradient(to bottom, #eab308, #ca8a04); 
  box-shadow: 0 2px 0 #854d0e !important; 
}
.tab-btn[data-tab="skins"].active { 
  background: linear-gradient(to bottom, #06b6d4, #0891b2); 
  box-shadow: 0 2px 0 #155e75 !important; 
}
.tab-btn[data-tab="achievements"].active { 
  background: linear-gradient(to bottom, #f59e0b, #d97706); 
  box-shadow: 0 2px 0 #92400e !important; 
}
.tab-btn[data-tab="settings"].active { 
  background: linear-gradient(to bottom, #9333ea, #7e22ce); 
  box-shadow: 0 2px 0 #581c87 !important; 
}

.tab-btn:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.2) !important;
}

/* Tab Content */
.tab-content-container {
  flex: 1;
  padding: 12px 0;
  overflow-y: auto;
  scrollbar-width: none;
  cursor: grab;
  user-select: none;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: none;
  scroll-behavior: auto;
}

.tab-content-container.drag-scrolling {
  cursor: grabbing;
}

.tab-content-container::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.tab-content-container button,
.tab-content-container input,
.tab-content-container select,
.tab-content-container textarea,
.tab-content-container a {
  user-select: auto;
}

.tab-content {
  display: none;
  animation: fadeIn 0.3s ease-out;
}

.tab-content.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.section-title {
  font-size: 1.25rem;
  font-weight: 900;
  margin-bottom: 24px;
  letter-spacing: 0.1em;
  color: white;
  text-transform: uppercase;
}

.section-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 24px;
  line-height: 1.5;
}

/* Shared upgrade-style surfaces */
.upgrade-item,
.achievement-item,
.prestige-perk-row,
.skin-item,
.setting-row,
.dev-controls,
.modal,
.prestige-req-card,
.prestige-stat,
.achievement-toast {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

@media (hover: hover) and (pointer: fine) {
  .upgrade-item:hover,
  .achievement-item:hover,
  .prestige-perk-row:hover:not(:disabled),
  .skin-item:hover,
  .setting-row:hover {
    border-color: rgba(59, 130, 246, 0.4);
    background: linear-gradient(145deg, #162136, #0a0f1d);
    transform: scale(0.995);
  }
}

.upgrade-item::before,
.achievement-item::before,
.skin-item::before,
.setting-row::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent 28%),
    radial-gradient(circle at top right, rgba(250, 204, 21, 0.14), transparent 42%),
    radial-gradient(circle at bottom left, rgba(59, 130, 246, 0.12), transparent 38%);
  opacity: 0.9;
  pointer-events: none;
  z-index: 0;
}

.upgrade-item > *,
.achievement-item > *,
.skin-item > *,
.setting-row > * {
  position: relative;
  z-index: 1;
}

.buy-btn,
.prestige-btn-main,
.got-it-btn,
.reset-btn,
.dev-btn,
.toggle,
.sub-tab-btn,
.achievement-status-btn {
  font-weight: 900;
}

/* Upgrades specific */
.upgrades-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.upgrade-item {
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  font-family: var(--font-family-main);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(15, 23, 42, 0.72)),
    rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-left: 4px solid rgba(59, 130, 246, 0.58);
}

.upgrade-item::after {
  content: "";
  position: absolute;
  inset: auto 12px 10px 12px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
  pointer-events: none;
  z-index: 0;
}

.upgrade-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 16px;
  position: relative;
  box-shadow: inset -4px -4px 8px rgba(0,0,0,0.4), inset 4px 4px 8px rgba(255,255,255,0.2);
}

.upgrade-icon::after {
  content: '';
  position: absolute;
  top: 15%; left: 15%; width: 30%; height: 30%;
  background: radial-gradient(circle, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0) 70%);
  border-radius: 50%;
}

.upgrade-info { flex: 1; }
.upgrade-name { font-family: var(--font-family-main); font-weight: 900; font-size: 1rem; color: var(--text-main); }
.upgrade-desc { font-family: var(--font-family-main); color: var(--text-muted); font-size: 0.8rem; font-weight: 600; }

/* ---- UPGRADE TOOLTIP ---- */
.upgrade-desc-tip {
  display: block;
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
  line-height: 1.3;
}

/* ---- UPGRADE PULSE HINT ---- */
@keyframes upgrade-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.5); }
  50% { box-shadow: 0 0 0 8px rgba(251, 191, 36, 0); }
}

.upgrade-item.can-afford-pulse {
  animation: upgrade-pulse 1.5s ease-in-out infinite;
}

.buy-btn {
  flex: 0 0 92px;
  width: 92px;
  height: 44px;
  border-radius: 12px;
  font-family: var(--font-family-main);
  font-weight: 900;
  font-size: 1.1rem;
  line-height: 1;
  letter-spacing: 0.01em;
  border: none;
  cursor: pointer;
  background: linear-gradient(to bottom, #2563eb, #1d4ed8);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 0 #1e3a8a;
  transition: all 0.1s;
  margin-left: auto;
  margin-right: 2px;
  overflow: visible;
}

.buy-btn:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 2px 0 #1e3a8a;
}

.buy-btn:disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* Prestige Tab specific */
.prestige-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.prestige-info .section-title {
  margin-bottom: 12px;
}

.prestige-panel-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.prestige-hero-card {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background:
    radial-gradient(circle at top right, rgba(250, 204, 21, 0.18), transparent 38%),
    radial-gradient(circle at bottom left, rgba(59, 130, 246, 0.16), transparent 34%),
    rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

.prestige-hero-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.prestige-kicker {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--accent-cyan);
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.prestige-hero-head h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  color: white;
}

.prestige-hero-head p {
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.5;
  max-width: 28ch;
}

.prestige-hero-badge {
  min-width: 106px;
  padding: 12px 14px;
  text-align: center;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(250, 204, 21, 0.18), rgba(15, 23, 42, 0.88));
  border: 1px solid rgba(250, 204, 21, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.prestige-hero-badge span {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.prestige-hero-badge strong {
  display: block;
  color: var(--accent-yellow);
  font-size: 1.5rem;
  line-height: 1;
  text-shadow: 0 0 18px rgba(250, 204, 21, 0.22);
}

.prestige-progress {
  padding: 14px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.prestige-progress-head,
.prestige-progress-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.prestige-progress-head {
  margin-bottom: 10px;
}

.prestige-progress-head span,
.prestige-progress-foot span {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.prestige-progress-head strong {
  color: white;
  font-size: 0.84rem;
}

.prestige-progress-value {
  margin-left: auto;
  text-align: right;
  font-size: 0.74rem;
  line-height: 1.15;
  font-weight: 800;
  max-width: 66%;
  white-space: normal;
}

.prestige-progress-track {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
}

.prestige-progress-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-yellow));
  box-shadow: 0 0 16px rgba(34, 211, 238, 0.35);
}

.prestige-progress-foot {
  margin-top: 10px;
}

.prestige-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.prestige-loop-action {
  display: flex;
  justify-content: center;
}

.prestige-loop-stats {
  margin-top: 2px;
}

.prestige-stat {
  padding: 16px 14px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(15, 23, 42, 0.72)),
    rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.prestige-stat span {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.prestige-stat strong {
  color: white;
  font-size: 1.2rem;
}

.prestige-perk-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.prestige-perk-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 15px 16px;
  color: white;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.prestige-perk-row::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--accent-cyan), var(--accent-yellow));
  opacity: 0.85;
}

.prestige-perk-meta,
.prestige-perk-side {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.prestige-perk-side {
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.prestige-perk-row:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.prestige-perk-name {
  font-weight: 800;
  font-size: 0.98rem;
}

.prestige-perk-desc {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.prestige-perk-level {
  color: var(--accent-cyan);
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.prestige-buy-btn {
  flex: 0 0 92px;
  width: 92px;
  height: 44px;
  border-radius: 12px;
  font-family: var(--font-family-main);
  font-weight: 900;
  font-size: 1.1rem;
  line-height: 1;
  letter-spacing: 0.01em;
  border: none;
  cursor: pointer;
  background: linear-gradient(to bottom, #2563eb, #1d4ed8);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 0 #1e3a8a;
  transition: all 0.1s;
  margin-right: 2px;
  overflow: visible;
}

.prestige-buy-btn:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 2px 0 #1e3a8a;
}

.prestige-buy-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.prestige-btn-main {
  width: min(240px, 100%);
  min-height: 44px;
  padding: 0 18px;
  border: none;
  background: linear-gradient(to bottom, #22c55e, #16a34a);
  color: white;
  font-weight: 900;
  font-size: 0.96rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  align-self: center;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s, filter 0.18s;
  box-shadow: 0 4px 0 #166534;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.prestige-btn-main:not(:disabled):hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
  box-shadow:
    0 6px 0 #166534,
    0 16px 30px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(34, 197, 94, 0.14),
    0 0 22px rgba(34, 197, 94, 0.16);
}

.prestige-btn-main:disabled {
  opacity: 0.56;
  cursor: not-allowed;
}

.prestige-btn-main:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow:
    0 2px 0 #166534,
    0 8px 16px rgba(0, 0, 0, 0.2),
    inset 0 2px 8px rgba(0, 0, 0, 0.18);
}

/* Skins Tab specific */
.skins-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.skin-item {
  padding: 18px 16px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  border: 2px solid transparent;
  min-height: 168px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(15, 23, 42, 0.72)),
    rgba(30, 41, 59, 0.56);
  border-color: rgba(148, 163, 184, 0.08);
}

.skin-item.active {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.12);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.55), 0 0 18px rgba(34, 197, 94, 0.18);
}

.skin-item.active .skin-preview {
  filter: drop-shadow(0 0 10px rgba(34, 197, 94, 0.45));
}

.skin-item.locked {
  opacity: 1;
  filter: none;
}

.skin-item.locked .skin-preview,
.skin-item.locked .skin-level-badge {
  opacity: 0.55;
  filter: grayscale(0.45);
}

.skin-item.locked .skin-buy-btn {
  opacity: 1;
  filter: none;
}

.skin-item.unlocked:hover {
  transform: translateY(-2px) scale(1.01);
}

.skin-lock-icon {
  position: absolute;
  width: 26px;
  height: 26px;
  z-index: 2;
  opacity: 0.95;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.45));
}

.skin-preview {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  box-shadow: none;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent !important;
}

.skin-preview-canvas {
  width: 72px;
  height: 72px;
  display: block;
}

.bucket-skin-item {
  height: 203.19px;
  box-sizing: border-box;
}

.skin-core {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  z-index: 0;
  box-shadow: none;
}

.skin-core-pin {
  inset: 0;
  border-radius: 50%;
}

.skin-star {
  position: absolute;
  width: 22px;
  height: 22px;
  z-index: 1;
  filter: none;
}

.skin-shine {
  display: none;
}

.skin-emoji {
  font-size: 1.8rem;
  z-index: 1;
}

.skin-name { font-weight: 800; font-size: 0.92rem; text-transform: uppercase; letter-spacing: 0.05em; text-align: center; }

.skin-meta-row {
  width: 100%;
  display: flex;
  justify-content: var(--skin-meta-justify, center);
  align-items: center;
  gap: 8px;
}

.skin-status {
  font-family: var(--skin-status-font-family, var(--font-family-main));
  font-size: var(--skin-status-font-size, 1rem);
  font-weight: var(--skin-status-font-weight, 800);
  letter-spacing: var(--skin-status-letter-spacing, 0.05em);
  line-height: var(--skin-status-line-height, 1.1);
  text-align: var(--skin-status-text-align, center);
  padding: 6px 10px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-muted);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
  text-transform: var(--skin-status-transform, uppercase);
  white-space: nowrap;
}

.skin-status.skin-status-locked {
  white-space: normal;
}

.skin-item.active .skin-status,
.skin-status.status-active {
  background: linear-gradient(to bottom, #22c55e, #15803d);
  color: white;
  box-shadow: 0 3px 0 #14532d;
}

.skin-buy-btn {
  width: 86px;
  height: 40px;
  border: none;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(to bottom, #84cc16, #3f6212);
  box-shadow: 0 4px 0 #365314;
  cursor: pointer;
  color: #ffffff;
  position: relative;
  z-index: 3;
}

.skin-buy-btn img {
  width: 18px;
  height: 18px;
  display: block;
}

.skin-buy-cost {
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  line-height: 1;
}

.skin-level-badge {
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  color: #dbeafe;
  text-transform: uppercase;
}

.skin-level-badge:empty {
  display: none;
}

.skin-item.locked .skin-status {
  background: transparent;
  color: #ffffff;
  box-shadow: none;
  padding: 0;
  border-radius: 0;
  letter-spacing: 0.02em;
}

.skin-item.locked .skin-level-badge {
  color: #93c5fd;
}

/* Sub Tab Navigation */
.sub-tab-nav {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  background: rgba(0, 0, 0, 0.4);
  padding: 6px;
  border-radius: 16px;
  position: relative;
  z-index: 1;
}

.sub-tab-indicator {
  position: absolute;
  top: 6px;
  left: 6px;
  width: calc(33.333% - 8px);
  height: calc(100% - 12px);
  border-radius: 12px;
  transition:
    left 0.28s cubic-bezier(0.22, 1, 0.36, 1),
    background 0.2s ease,
    box-shadow 0.2s ease;
  z-index: -1;
}

/* Sub Tab Indicator Colors */
.sub-tab-nav:has([data-sub-tab="balls"].active) .sub-tab-indicator {
  background: linear-gradient(135deg, #06b6d4, #0891b2);
  box-shadow: 0 4px 0 #164e63, 0 8px 15px rgba(6, 182, 212, 0.3);
  left: 6px;
}

.sub-tab-nav:has([data-sub-tab="pins"].active) .sub-tab-indicator {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  box-shadow: 0 4px 0 #1e3a8a, 0 8px 15px rgba(37, 99, 235, 0.3);
  left: calc(33.333% + 1px);
}

.sub-tab-nav:has([data-sub-tab="buckets"].active) .sub-tab-indicator {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  box-shadow: 0 4px 0 #92400e, 0 8px 15px rgba(245, 158, 11, 0.3);
  left: calc(66.666% - 2px);
}

.sub-tab-btn {
  flex: 1;
  padding: 12px;
  background: transparent;
  border: none;
  border-radius: 12px;
  color: var(--text-muted);
  font-weight: 800;
  font-size: 0.75rem;
  cursor: pointer;
  transition: color 0.18s ease, transform 0.18s ease, text-shadow 0.18s ease;
  letter-spacing: 0.1em;
  z-index: 2;
}

.sub-tab-btn.active {
  color: white;
  transform: translateY(-1px) scale(1.02);
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.22);
}

.sub-tab-btn:hover:not(.active) {
  color: white;
  transform: translateY(-1px);
}

.sub-tab-panel {
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transform-origin: top center;
  transition:
    opacity 0.2s ease,
    transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.sub-tab-panel.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.sub-tab-panel.is-hiding {
  opacity: 0;
  transform: translateY(-4px) scale(0.99);
}

/* Settings Tab specific */
.settings-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.setting-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  gap: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(15, 23, 42, 0.68)),
    rgba(15, 23, 42, 0.56);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-left: 4px solid rgba(34, 211, 238, 0.45);
}

.setting-label { font-weight: 700; font-size: 0.95rem; }

.toggle-group { display: flex; align-items: center; gap: 12px; }

.setting-slider-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
  max-width: 240px;
}

.setting-slider {
  flex: 1;
  min-width: 0;
}

.setting-percent {
  min-width: 52px;
  text-align: right;
  font-weight: 900;
  font-size: 0.8rem;
  color: var(--accent-yellow);
}

.toggle {
  width: 44px; height: 24px;
  background: #1e293b; border-radius: 20px;
  padding: 3px; cursor: pointer; border: none;
  display: flex; align-items: center;
}

.toggle-on { background: var(--accent-green) !important; }

.toggle-knob {
  width: 18px; height: 18px; background: white;
  border-radius: 50%; transition: transform 0.2s;
}

.toggle-knob.active { transform: translateX(20px); }

.toggle-label { font-weight: 900; font-size: 0.75rem; color: var(--text-muted); min-width: 25px; }

.reset-btn {
  margin-top: 12px;
  padding: 16px;
  background: #991b1b;
  color: white;
  border: none;
  border-radius: 12px;
  font-weight: 900;
  text-transform: uppercase;
  cursor: pointer;
}

#reset-game-btn {
  background: linear-gradient(180deg, #ef4444 0%, #991b1b 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom-color: rgba(0, 0, 0, 0.45);
  box-shadow:
    0 4px 0 #5f1111,
    0 10px 18px rgba(239, 68, 68, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transform: translateY(0);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
}

#reset-game-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

#reset-game-btn:active {
  transform: translateY(3px);
  box-shadow:
    0 1px 0 #5f1111,
    0 5px 10px rgba(239, 68, 68, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Level System (Inside HUD) */
.level-bar-bg {
  position: relative;
  height: 24px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.level-bar-fill {
  position: absolute; left: 0; top: 0; height: 100%;
  background: linear-gradient(to right, #6b21a8, #9333ea);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.level-text {
  position: relative; z-index: 2;
  font-weight: 900; font-size: 1rem; color: white;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* Modals */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(2, 6, 23, 0.82);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  z-index: 10000;
}

.modal {
  width: min(100%, 520px);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(11, 20, 49, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.modal-offline {
  max-width: 440px;
}

.modal-offline .modal-primary-btn {
  align-self: center;
  min-width: 180px;
}

.reset-modal {
  max-width: 520px;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.modal-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.modal-icon-danger {
  color: #f87171;
  background: rgba(248, 113, 113, 0.1);
  border-color: rgba(248, 113, 113, 0.18);
}

.modal-copy {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modal-kicker {
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-cyan);
}

.modal-kicker-danger {
  color: #f87171;
}

.modal-title {
  font-size: 1.55rem;
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 0.03em;
  color: var(--text-main);
}

.modal-title-danger {
  color: #fecaca;
}

.modal-desc {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
  font-weight: 600;
}

.modal-strong {
  color: white;
}

.modal-stat-card {
  border-radius: 18px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(15, 23, 42, 0.72);
}

.modal-stat-card-info {
  border-color: rgba(0, 229, 255, 0.18);
  background: linear-gradient(180deg, rgba(0, 229, 255, 0.08), rgba(15, 23, 42, 0.7));
}

.modal-stat-card-danger {
  border-color: rgba(248, 113, 113, 0.16);
  background: linear-gradient(180deg, rgba(248, 113, 113, 0.08), rgba(15, 23, 42, 0.7));
}

.modal-stat-label {
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.modal-stat-value {
  font-size: 2.4rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: var(--accent-yellow);
}

.modal-stat-text {
  color: var(--text-main);
  font-size: 0.92rem;
  line-height: 1.5;
  font-weight: 600;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}



.got-it-btn {
  background: var(--accent-yellow); color: #451a03;
  font-weight: 900; font-size: 1.25rem; padding: 14px 40px;
  border: none; border-radius: 16px; cursor: pointer;
}

.modal-primary-btn,
.modal-secondary-btn,
.modal-danger-btn {
  min-height: 48px;
  padding: 12px 18px;
  border-radius: 14px;
  border: none;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease, box-shadow 0.15s ease;
}

.modal-primary-btn:hover,
.modal-secondary-btn:hover,
.modal-danger-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.modal-primary-btn:active,
.modal-secondary-btn:active,
.modal-danger-btn:active {
  transform: translateY(1px);
}

.modal-primary-btn {
  align-self: flex-end;
  color: #0f172a;
  background: linear-gradient(180deg, #fde68a 0%, #fbbf24 100%);
  box-shadow: 0 4px 0 #a16207, 0 10px 22px rgba(251, 191, 36, 0.18);
}

.modal-secondary-btn {
  color: #e2e8f0;
  background: linear-gradient(180deg, #475569 0%, #334155 100%);
  box-shadow: 0 4px 0 #1e293b, 0 10px 22px rgba(15, 23, 42, 0.22);
}

.modal-danger-btn {
  color: white;
  background: linear-gradient(180deg, #ef4444 0%, #b91c1c 100%);
  box-shadow: 0 4px 0 #7f1d1d, 0 10px 22px rgba(239, 68, 68, 0.22);
}

.close-btn { background: none; border: none; cursor: pointer; }

/* Achievement List */
.achievements-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.achievement-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px;
  font-family: var(--font-family-main);
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.12), transparent 36%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(15, 23, 42, 0.74)),
    rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-left: 4px solid rgba(245, 158, 11, 0.58);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.03);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.achievement-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.04), transparent 30%, transparent 70%, rgba(255, 255, 255, 0.02));
  pointer-events: none;
}

.achievement-item:hover {
  transform: translateY(-1px);
  border-color: rgba(245, 158, 11, 0.18);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.24), 0 0 0 1px rgba(245, 158, 11, 0.08);
}

.achievement-item.unlocked {
  border-color: rgba(245, 158, 11, 0.3);
}

.achievement-item.locked {
  border-color: rgba(255, 255, 255, 0.04);
  opacity: 0.6;
}

.achievement-icon {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-right: 16px;
  position: relative;
  box-shadow: inset -4px -4px 8px rgba(0,0,0,0.4), inset 4px 4px 8px rgba(255,255,255,0.2);
}

.achievement-icon::after {
  content: '';
  position: absolute;
  top: 15%; left: 15%; width: 30%; height: 30%;
  background: radial-gradient(circle, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0) 70%);
  border-radius: 50%;
}

.achievement-icon svg {
  width: 28px;
  height: 28px;
  stroke: currentColor;
  color: inherit;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.24));
}

.achievement-info { flex: 1; }

.achievement-name {
  font-family: var(--font-family-main);
  font-weight: 800;
  font-size: 1rem;
  color: var(--text-main);
}

.achievement-desc {
  font-family: var(--font-family-main);
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
}

.achievement-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  min-width: 110px;
}

.achievement-status-text {
  display: block;
  font-size: 1rem;
  line-height: 1;
  font-weight: 900;
}

.achievement-status-reward {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 4px;
  font-size: 0.78rem;
  font-weight: 900;
  color: #fde68a;
  letter-spacing: 0.06em;
}

.achievement-status-reward img {
  width: 16px;
  height: 16px;
  display: block;
}

.achievement-status-btn {
  color: white;
  font-weight: 900;
  font-size: 0.95rem;
  width: 102px;
  height: 48px;
  padding: 4px 10px 3px;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(to bottom, #3b82f6, #1d4ed8);
  box-shadow: 0 4px 0 #1e3a8a, 0 8px 18px rgba(59, 130, 246, 0.18);
  cursor: pointer;
}

.achievement-status-btn:disabled {
  background: linear-gradient(to bottom, #64748b, #334155);
  box-shadow: 0 4px 0 #1e293b, 0 8px 18px rgba(0, 0, 0, 0.16);
  color: #e2e8f0;
  opacity: 0.72;
  cursor: default;
}

.achievement-item.claimable .achievement-status-btn {
  background: linear-gradient(to bottom, #60a5fa, #2563eb);
  box-shadow: 0 4px 0 #1d4ed8, 0 10px 20px rgba(37, 99, 235, 0.25);
}

.achievement-item.claimed .achievement-status-btn {
  background: linear-gradient(to bottom, #fde68a, #f59e0b);
  box-shadow: 0 4px 0 #b45309, 0 10px 20px rgba(245, 158, 11, 0.22);
  color: white;
  opacity: 1 !important;
}

.achievement-item.claimed .achievement-status-reward {
  display: none;
}

.achievement-item.claimed .achievement-status-text {
  color: white;
  font-size: 1.15rem;
}

.achievement-item.disabled .achievement-status-btn {
  background: linear-gradient(to bottom, #64748b, #475569);
  box-shadow: 0 4px 0 #334155, 0 8px 16px rgba(0, 0, 0, 0.18);
  color: #cbd5e1;
}

.achievement-item.disabled .achievement-icon {
  filter: grayscale(0.25);
  opacity: 0.9;
}

/* Achievement Toast */
.achievement-toast {
  position: absolute;
  top: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(-84px);
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.2), transparent 28%),
    radial-gradient(circle at bottom left, rgba(0, 229, 255, 0.12), transparent 30%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(7, 12, 27, 0.98));
  border: 1px solid rgba(245, 158, 11, 0.5);
  border-radius: 18px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  z-index: 500;
  box-shadow:
    0 14px 40px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(245, 158, 11, 0.12),
    0 0 24px rgba(245, 158, 11, 0.18);
  min-width: 320px;
  max-width: 460px;
  pointer-events: none;
  overflow: hidden;
}

.achievement-toast::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.08), transparent 34%, transparent 66%, rgba(255, 255, 255, 0.04));
  pointer-events: none;
}

.achievement-toast .toast-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.24), rgba(15, 23, 42, 0.84));
  border: 1px solid rgba(245, 158, 11, 0.36);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  color: var(--toast-accent, var(--accent-yellow));
  flex-shrink: 0;
}

.achievement-toast .toast-icon svg {
  width: 30px;
  height: 30px;
  stroke: currentColor;
  color: inherit;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.22));
}

.achievement-toast .toast-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.achievement-toast .toast-label {
  font-size: 0.64rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--toast-accent, var(--accent-yellow));
}

.achievement-toast .toast-name {
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: white;
}

.achievement-toast .toast-desc {
  font-size: 0.8rem;
  line-height: 1.35;
  color: rgba(226, 232, 240, 0.78);
}

.achievement-toast.toast-show {
  animation: toastSlideIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.achievement-toast.toast-hide {
  animation: toastSlideOut 0.4s ease-in forwards;
}

@keyframes toastSlideIn {
  from { transform: translateX(-50%) translateY(-84px); opacity: 0; }
  to   { transform: translateX(-50%) translateY(0);    opacity: 1; }
}

@keyframes toastSlideOut {
  from { transform: translateX(-50%) translateY(0);    opacity: 1; }
  to   { transform: translateX(-50%) translateY(-84px); opacity: 0; }
}

.toast-icon { font-size: 2.2rem; flex-shrink: 0; }

.toast-body { flex: 1; }

.toast-label {
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  color: var(--accent-yellow);
  text-transform: uppercase;
  margin-bottom: 2px;
}

.toast-name {
  font-weight: 900;
  font-size: 1rem;
  color: white;
}

.toast-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Custom Scrollbar */
.custom-scrollbar::-webkit-scrollbar { width: 4px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 10px; }

.hidden { display: none !important; }

/* Developer Panel */
.dev-panel {
  position: absolute;
  bottom: var(--dev-bottom);
  left: var(--dev-left);
  z-index: 9999;
  display: flex;
  flex-direction: column-reverse;
  gap: 12px;
}

.dev-toggle {
  width: 44px;
  height: 44px;
  background: rgba(30, 41, 59, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: var(--text-muted);
  font-size: 0.65rem;
  font-weight: 900;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dev-toggle:hover {
  background: rgba(30, 41, 59, 0.9);
  color: white;
  border-color: var(--accent-blue);
}

.visual-toggle {
  border-color: rgba(0, 229, 255, 0.4);
}

.visual-toggle:hover {
  border-color: var(--accent-cyan);
}

.visual-controls {
  border-color: var(--accent-cyan);
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.9), inset 0 0 20px rgba(6, 182, 212, 0.12);
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: min(1120px, calc(100vw - 40px));
  max-width: 1120px;
  max-height: min(560px, calc(100vh - 60px));
  min-height: 0;
  overflow: hidden;
  grid-template-columns: none;
  padding: 20px;
  border-width: 2px;
  border-style: solid;
  border-radius: 24px;
}

.visual-sections-shell {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 229, 255, 0.55) rgba(255, 255, 255, 0.08);
}

.visual-panel-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.visual-panel-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.visual-panel-kicker {
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-cyan);
}

.visual-panel-title {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--text-main);
}

.visual-panel-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
  max-width: 500px;
}

.visual-panel-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
}

.visual-sections {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 280px;
  grid-template-rows: repeat(2, auto);
  gap: 14px;
  align-items: start;
  width: max-content;
  min-width: 100%;
  min-height: 0;
  padding-bottom: 6px;
}

.visual-sections-shell::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

.visual-sections-shell::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
}

.visual-sections-shell::-webkit-scrollbar-thumb {
  background: rgba(0, 229, 255, 0.55);
  border-radius: 999px;
  border: 2px solid rgba(11, 20, 49, 0.95);
}

.visual-sections-shell::-webkit-scrollbar-corner {
  background: rgba(255, 255, 255, 0.08);
}

.visual-section {
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 280px;
  max-width: 280px;
  min-height: 0;
  overflow: hidden;
}

.visual-section-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.visual-section-title {
  font-size: 0.98rem;
  font-weight: 900;
  color: var(--text-main);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.visual-section-desc {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.visual-section-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  overflow: visible;
  padding-right: 4px;
}

.visual-control {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.visual-control-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.visual-control-label {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.visual-control-value {
  font-size: 0.72rem;
  color: var(--accent-cyan);
  font-weight: 900;
  letter-spacing: 0.03em;
  text-align: right;
  white-space: nowrap;
  max-width: none;
  overflow: visible;
  text-overflow: clip;
}

.visual-control-input {
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(0, 229, 255, 0.28);
  background: rgba(0, 0, 0, 0.28);
  color: white;
  padding: 8px 10px;
  font-family: var(--font-family-main);
  font-size: 0.8rem;
}

.visual-control-input[type="range"] {
  padding: 0;
  height: 28px;
  accent-color: var(--accent-cyan);
}

.visual-control-input[type="color"] {
  height: 36px;
  padding: 3px;
}

.visual-control-input[type="text"],
.visual-control-select {
  min-height: 38px;
}

.visual-control-input:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 2px rgba(0, 229, 255, 0.12);
}

.visual-reset-btn {
  align-self: flex-end;
}

@media (max-width: 1100px) {
  .visual-controls {
    width: min(94vw, 920px);
    max-height: calc(100vh - 90px);
  }

  .visual-panel-header {
    flex-direction: column;
  }

  .visual-sections {
    grid-auto-columns: 240px;
  }

  .visual-section {
    width: 240px;
    max-width: 240px;
  }

  .visual-panel-actions {
    width: 100%;
    justify-content: flex-start;
  }
}

.visual-controls .dev-group {
  margin-bottom: 0;
}

.visual-reset-btn {
  padding: 7px 10px;
  min-width: 56px;
  font-size: 0.68rem;
  line-height: 1;
}

.dev-controls:not(.visual-controls) {
  display: grid;
  grid-template-columns: repeat(3, 280px);
  gap: 8px 24px;
  background: rgba(11, 20, 49, 0.95);
  backdrop-filter: blur(16px);
  padding: 24px;
  border-radius: 24px;
  border: 2px solid var(--accent-blue);
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.9), inset 0 0 20px rgba(59, 130, 246, 0.1);
  max-height: 680px;
  overflow-y: auto;
  animation: slideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  width: max-content;
}

.dev-controls:not(.visual-controls) hr {
  grid-column: 1 / -1;
  width: 100%;
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 10px 0;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(10px) scale(0.9); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.dev-btn {
  padding: 10px 16px;
  background: linear-gradient(135deg, #1e293b, #0f172a);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #60a5fa;
  font-weight: 800;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.dev-btn:hover {
  background: var(--accent-blue);
  color: white;
  transform: scale(1.05);
}

.dev-btn:active {
  transform: scale(0.95);
}

.dev-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
}

.dev-group label {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 700;
  display: flex;
  justify-content: space-between;
}

.dev-group span {
  color: var(--accent-cyan);
}

.dev-group input[type="range"] {
  width: 100%;
  cursor: pointer;
}

.dev-control-inline {
  display: flex;
  gap: 8px;
  align-items: center;
}

.dev-control-inline input[type="range"] {
  flex: 1;
  min-width: 0;
}

.dev-number-input {
  width: 64px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--accent-cyan);
  color: white;
  border-radius: 4px;
  font-size: 0.7rem;
  padding: 2px 4px;
  flex: 0 0 auto;
}

.dev-number-input:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(0, 229, 255, 0.12);
}

/* Portrait modda döndür uyarısı */
#rotate-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: #0a0a1a;
  z-index: 99999;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  color: white;
  font-family: sans-serif;
  text-align: center;
}

#rotate-overlay svg {
  animation: spin-hint 1.5s ease-in-out infinite alternate;
}

@keyframes spin-hint {
  from { transform: rotate(0deg); }
  to   { transform: rotate(90deg); }
}

@media screen and (orientation: portrait) {
  #rotate-overlay { display: flex; }
}


/* Mobile anti-flicker/performance tuning */
@media (hover: none), (pointer: coarse) {
  .tab-content {
    animation: none;
  }

  .upgrade-item:hover,
  .achievement-item:hover,
  .prestige-perk-row:hover:not(:disabled),
  .skin-item:hover,
  .setting-row:hover {
    transform: none;
  }

  .upgrade-item,
  .achievement-item,
  .prestige-perk-row,
  .skin-item,
  .setting-row,
  .prestige-hero-card,
  .prestige-stat,
  .modal,
  .achievement-toast {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .buy-btn,
  .prestige-buy-btn,
  .prestige-btn-main,
  .tab-btn,
  .skin-buy-btn,
  .achievement-status-btn {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
}


/* --- Full Launch MVP: Rewarded Boost Dock --- */
.boost-dock {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 86px;
  margin-top: 2px;
}

.boost-card {
  --boost-accent: #facc15;
  position: relative;
  width: 86px;
  min-height: 86px;
  border: none;
  border-radius: 0;
  padding: 8px;
  color: white;
  background: transparent;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none;
  cursor: pointer;
  text-align: left;
  pointer-events: auto;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), filter 0.14s ease, box-shadow 0.14s ease;
}

.boost-card:hover:not(:disabled) { transform: translateY(-1px); filter: brightness(1.08); }
.boost-card:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 2px 0 rgba(0,0,0,0.4); }
.boost-card:disabled { cursor: default; opacity: 0.62; filter: grayscale(0.25); pointer-events: none; }
.boost-card.boost-active {
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--boost-accent) 28%, transparent), transparent 52%),
    linear-gradient(180deg, rgba(12, 18, 28, 0.96), rgba(22, 31, 42, 0.95));
  border-radius: 16px;
  border: 1px solid color-mix(in srgb, var(--boost-accent) 58%, rgba(255, 255, 255, 0.18));
  box-shadow:
    0 4px 0 rgba(0, 0, 0, 0.36),
    0 0 18px color-mix(in srgb, var(--boost-accent) 28%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.boost-card.boost-cooldown {
  background: transparent;
  box-shadow: none;
}

.boost-card.boost-cooldown .boost-icon-art {
  display: none;
}

.boost-card-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 8px;
  width: 100%;
}

.boost-icon-art {
  width: 62px;
  height: 62px;
  object-fit: contain;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.35));
}

.boost-status {
  display: none;
}

.boost-bar-track {
  display: none;
  position: relative;
  width: 100%;
  height: 16px;
  border-radius: 7px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025)),
    rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    inset 0 1px 2px rgba(255, 255, 255, 0.08),
    inset 0 -2px 4px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.boost-card.boost-active .boost-bar-track {
  display: block;
}

.boost-card.boost-active .boost-bar-track .boost-status {
  display: flex;
  position: absolute;
  inset: 0;
  align-items: center;
  justify-content: center;
  z-index: 2;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  transform: translateY(0.5px);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.7);
  pointer-events: none;
}

.boost-card.boost-active[data-boost-id="autoFrenzy"] .boost-bar-track .boost-status {
  color: #1f2937;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.35);
}

.boost-bar-fill {
  display: block;
  width: 0%;
  height: 100%;
  position: relative;
  z-index: 1;
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0) 46%),
    linear-gradient(90deg, color-mix(in srgb, var(--boost-accent) 74%, white), var(--boost-accent));
  box-shadow:
    0 0 12px color-mix(in srgb, var(--boost-accent) 38%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -2px 4px rgba(0, 0, 0, 0.12);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), filter 0.2s ease;
  overflow: hidden;
}

.boost-card.boost-active .boost-bar-fill {
  filter: saturate(1.15) brightness(1.05);
}

.boost-bar-fill::after {
  content: '';
  position: absolute;
  left: 4px;
  right: 4px;
  top: 3px;
  height: 35%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  opacity: 0.62;
  pointer-events: none;
}

.boost-spawn {
  animation: boostSpawn 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: center;
  will-change: transform, opacity, filter;
}

@keyframes boostSpawn {
  0% {
    opacity: 0;
    transform: translateY(8px) scale(0.78);
    filter: brightness(0.9);
  }
  72% {
    opacity: 1;
    transform: translateY(-1px) scale(1.08);
    filter: brightness(1.08);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: brightness(1);
  }
}

/* --- Full Launch MVP: Rewarded Skin UI --- */
.skin-rarity {
  margin-top: -6px;
  margin-bottom: 3px;
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #93c5fd;
  text-align: center;
}

.skin-unlock-stack {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.skin-ad-btn {
  height: 40px;
  min-width: 84px;
  padding: 0 12px;
  border: none;
  border-radius: 12px;
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(180deg, #2563eb, #1d4ed8);
  box-shadow: 0 4px 0 #1e3a8a;
  cursor: pointer;
  position: relative;
  z-index: 3;
}

.skin-ad-btn img {
  width: 21px;
  height: 21px;
  display: block;
}

.skin-ad-btn span {
  font-size: 0.84rem;
  line-height: 1;
}

.skin-unlock-stack .skin-buy-btn { width: 62px; height: 36px; }
.rewarded-skin { border-color: rgba(250, 204, 21, 0.24); }

.bucket-placeholder-card {
  min-height: 176px;
  justify-content: center;
  align-items: center;
}

.bucket-placeholder-preview {
  display: flex;
  align-items: center;
  justify-content: center;
}

.bucket-placeholder-icon {
  font-size: 2.5rem;
  line-height: 1;
  filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.35));
}

/* --- Full Launch MVP: Achievement Road --- */
.achievement-road-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 18px 2px 8px;
  padding-top: 4px;
}

.achievement-road-title {
  color: #fff;
  font-size: 0.92rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.achievement-road-subtitle {
  color: rgba(255,255,255,0.7);
  font-size: 0.68rem;
  font-weight: 800;
  margin-top: 2px;
}

.achievement-road-line {
  flex: 1;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--road-color, #f59e0b), transparent);
  opacity: 0.75;
}

.achievement-progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: #cbd5e1;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.achievement-progress-track {
  flex: 1;
  height: 7px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.35);
}

.achievement-progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.25s ease;
}

.achievement-emoji { display: none; }

/* --- Full Launch MVP: Reward modals / ad state --- */
.reward-modal { max-width: 540px; }
.reward-modal-icon { font-size: 1.4rem; }
.reward-stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.reward-stat-value {
  color: #fff;
  font-size: 1.55rem;
  font-weight: 950;
  letter-spacing: -0.03em;
}
.reward-stat-value-hot { color: #fde68a; }
.reward-actions-equal { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.reward-actions-equal .modal-primary-btn,
.reward-actions-equal .modal-secondary-btn { width: 100%; align-self: stretch; }
.reward-actions-equal .modal-secondary-btn img { width: 18px; height: 18px; vertical-align: middle; margin-left: 3px; }

.ad-loading-overlay { z-index: 11000; }
.ad-loading-card {
  min-width: 260px;
  min-height: 160px;
  padding: 28px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.94));
  border: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #fff;
  font-weight: 900;
  text-align: center;
}
.ad-spinner {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 4px solid rgba(255,255,255,0.18);
  border-top-color: #fbbf24;
  animation: adSpin 0.8s linear infinite;
}
@keyframes adSpin { to { transform: rotate(360deg); } }

.reward-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  z-index: 12000;
  padding: 12px 18px;
  border-radius: 999px;
  color: white;
  font-weight: 950;
  letter-spacing: 0.03em;
  box-shadow: 0 14px 40px rgba(0,0,0,0.38);
  background: linear-gradient(180deg, #334155, #0f172a);
  border: 1px solid rgba(255,255,255,0.1);
  pointer-events: none;
}
.reward-toast-success { background: linear-gradient(180deg, #22c55e, #15803d); }
.reward-toast-error { background: linear-gradient(180deg, #ef4444, #991b1b); }
.reward-toast.toast-show { animation: rewardToastIn 0.22s ease-out both; }
.reward-toast.toast-hide { animation: rewardToastOut 0.22s ease-in both; }
@keyframes rewardToastIn { from { opacity: 0; transform: translate(-50%, 12px); } to { opacity: 1; transform: translate(-50%, 0); } }
@keyframes rewardToastOut { from { opacity: 1; transform: translate(-50%, 0); } to { opacity: 0; transform: translate(-50%, 12px); } }

@media (max-width: 900px) {
  .boost-dock { width: 96px; gap: 6px; }
  .boost-card { width: 96px; min-height: 74px; padding: 7px; border-radius: 14px; }
  .boost-icon-art { width: 48px; height: 48px; }
  .boost-status { font-size: 0.55rem; min-width: 30px; }
  .boost-bar-track { height: 11px; }
  .reward-actions-equal { grid-template-columns: 1fr; }
}
