/* Minecraft 听写助手 - 全局样式 */
*,*:where(*, *::before, *::after) { box-sizing: border-box; margin: 0; padding: 0; }

html, body, #root {
  min-height: 100vh;
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 40%, #0f172a 100%);
  background-attachment: fixed;
  color: #e2e8f0;
  font-family: 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  overflow-x: hidden;
}

/* Glassmorphism */
.glass {
  background: rgba(15,23,42,0.65);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 1rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
  transition: all 0.3s ease;
}
.glass:hover {
  border-color: rgba(255,255,255,0.2);
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

/* Minecraft Button */
.btn-minecraft {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  background: linear-gradient(180deg, #44bd32 0%, #2d8a1e 100%);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 0 #2d8a1e, 0 6px 12px rgba(0,0,0,0.3);
  position: relative;
  top: 0;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}
.btn-minecraft:hover { filter: brightness(1.1); transform: translateY(-2px); box-shadow: 0 6px 0 #2d8a1e, 0 8px 16px rgba(0,0,0,0.4); }
.btn-minecraft:active { top: 2px; box-shadow: 0 2px 0 #2d8a1e, 0 3px 6px rgba(0,0,0,0.3); }
.btn-minecraft:disabled { opacity: 0.5; cursor: not-allowed; filter: none; }

/* Text Colors */
.text-minecraft-green { color: #44bd32; }
.text-minecraft-red   { color: #e74c3c; }

/* Animations */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-12px); }
}
.animate-float { animation: float 3s ease-in-out infinite; }

@keyframes unlock-pop {
  0%   { transform: scale(0.3) rotate(-10deg); opacity: 0; }
  50%  { transform: scale(1.15) rotate(3deg);  opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}
.animate-unlock { animation: unlock-pop 0.6s cubic-bezier(0.34,1.56,0.64,1) forwards; }

@keyframes sparkle {
  0%, 100% { opacity: 0; transform: scale(0) rotate(0deg); }
  50%      { opacity: 1; transform: scale(1) rotate(180deg); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Achievement Cards */
.achievement-card {
  background: rgba(15,23,42,0.7);
  backdrop-filter: blur(12px);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 0.75rem;
  padding: 1rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}
.achievement-card.unlocked {
  border-color: #44bd32;
  box-shadow: 0 0 12px rgba(68,189,50,0.6), inset 0 0 12px rgba(68,189,50,0.08);
}
.achievement-card.unlocked:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 0 20px rgba(68,189,50,0.6), 0 8px 24px rgba(0,0,0,0.4);
}
.achievement-card.locked { opacity: 0.55; filter: grayscale(0.8); }
.achievement-card.locked:hover { opacity: 0.8; filter: grayscale(0.4); }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: rgba(15,23,42,0.5); border-radius: 3px; }
::-webkit-scrollbar-thumb { background: rgba(68,189,50,0.4); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(68,189,50,0.7); }

/* Range input */
input[type="range"] { -webkit-appearance: none; appearance: none; height: 6px; background: rgba(255,255,255,0.15); border-radius: 3px; outline: none; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 18px; height: 18px; background: #44bd32; border-radius: 50%; cursor: pointer; box-shadow: 0 0 6px rgba(68,189,50,0.6); }

/* Selection */
::selection { background: rgba(68,189,50,0.35); color: #fff; }
