* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scrollbar-width: thin;
  scrollbar-color: #5D4037 #2C1810;
}

html {
  scroll-behavior: smooth;
}

::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #2C1810;
}
::-webkit-scrollbar-thumb {
  background: #5D4037;
  border: 2px solid #2C1810;
}

#particle-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* Minecraft Button Style */
.mc-btn {
  position: relative;
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 600;
  padding: 10px 24px;
  border: 3px solid;
  image-rendering: pixelated;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.1s ease;
  cursor: pointer;
  font-size: 14px;
}

.mc-btn:active {
  transform: translateY(2px);
}

.mc-btn-gold {
  background: linear-gradient(180deg, #FFD600 0%, #F9A825 100%);
  border-color: #F57F17;
  color: #2C1810;
  box-shadow: inset 0 -3px 0 #E65100, inset 0 3px 0 #FFF176, 0 0 20px rgba(255,214,0,0.3);
}
.mc-btn-gold:hover {
  background: linear-gradient(180deg, #FFF176 0%, #FFD600 100%);
  box-shadow: inset 0 -3px 0 #E65100, inset 0 3px 0 #FFF9C4, 0 0 30px rgba(255,214,0,0.5);
}

.mc-btn-stone {
  background: linear-gradient(180deg, #757575 0%, #616161 100%);
  border-color: #424242;
  color: #E0E0E0;
  box-shadow: inset 0 -3px 0 #212121, inset 0 3px 0 #9E9E9E;
}
.mc-btn-stone:hover {
  background: linear-gradient(180deg, #9E9E9E 0%, #757575 100%);
  box-shadow: inset 0 -3px 0 #212121, inset 0 3px 0 #BDBDBD;
}

.mc-btn-discord {
  background: linear-gradient(180deg, #5865F2 0%, #4752C4 100%);
  border-color: #3C45A5;
  color: white;
  box-shadow: inset 0 -3px 0 #2D3494, inset 0 3px 0 #7983F5;
}
.mc-btn-discord:hover {
  background: linear-gradient(180deg, #7983F5 0%, #5865F2 100%);
  box-shadow: inset 0 -3px 0 #2D3494, inset 0 3px 0 #A5AEFF, 0 0 20px rgba(88,101,242,0.4);
}

.mc-btn-green {
  background: linear-gradient(180deg, #2E7D32 0%, #1B5E20 100%);
  border-color: #0D3B10;
  color: #C8E6C9;
  box-shadow: inset 0 -3px 0 #0A2E0C, inset 0 3px 0 #4CAF50;
}
.mc-btn-green:hover {
  background: linear-gradient(180deg, #43A047 0%, #2E7D32 100%);
  box-shadow: inset 0 -3px 0 #0A2E0C, inset 0 3px 0 #66BB6A, 0 0 20px rgba(46,125,50,0.4);
}

.mc-btn-brown {
  background: linear-gradient(180deg, #5D4037 0%, #3E2723 100%);
  border-color: #2C1810;
  color: #D7CCC8;
  box-shadow: inset 0 -3px 0 #1B0E09, inset 0 3px 0 #795548;
}
.mc-btn-brown:hover {
  background: linear-gradient(180deg, #795548 0%, #5D4037 100%);
}

.mc-btn-red {
  background: linear-gradient(180deg, #C62828 0%, #B71C1C 100%);
  border-color: #7F0000;
  color: #FFCDD2;
  box-shadow: inset 0 -3px 0 #5D0000, inset 0 3px 0 #EF5350;
}
.mc-btn-red:hover {
  background: linear-gradient(180deg, #E53935 0%, #C62828 100%);
  box-shadow: inset 0 -3px 0 #5D0000, inset 0 3px 0 #EF9A9A, 0 0 20px rgba(183,28,28,0.4);
}

/* Achievement popup style */
.achievement-popup {
  border: 4px solid #F9A825;
  background: linear-gradient(180deg, rgba(44,24,16,0.95) 0%, rgba(62,39,35,0.95) 100%);
  box-shadow: 0 0 30px rgba(255,214,0,0.2), inset 0 0 20px rgba(0,0,0,0.5);
}

/* Version card */
.version-card {
  border: 3px solid #5D4037;
  background: linear-gradient(180deg, rgba(62,39,35,0.9) 0%, rgba(44,24,16,0.95) 100%);
  transition: all 0.3s ease;
}
.version-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
}
.version-card.recommended:hover {
  border-color: #FFD600;
  box-shadow: 0 12px 40px rgba(255,214,0,0.15);
}
.version-card.classic:hover {
  border-color: #795548;
  box-shadow: 0 12px 40px rgba(121,85,72,0.15);
}
.version-card.newest:hover {
  border-color: #B71C1C;
  box-shadow: 0 12px 40px rgba(183,28,28,0.15);
}

/* FAQ accordion */
.faq-item {
  border: 2px solid #5D4037;
  background: rgba(62,39,35,0.6);
  transition: all 0.3s ease;
}
.faq-item:hover {
  border-color: #795548;
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
}
.faq-answer.open {
  max-height: 500px;
}

/* Section fade-in */
.section-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.section-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Glow text */
.glow-text {
  text-shadow: 0 0 10px rgba(255,214,0,0.5), 0 0 30px rgba(255,214,0,0.2);
}

.glow-green {
  text-shadow: 0 0 10px rgba(46,125,50,0.5), 0 0 30px rgba(46,125,50,0.2);
}

.glow-purple {
  text-shadow: 0 0 10px rgba(106,27,154,0.5), 0 0 30px rgba(106,27,154,0.2);
}

.glow-red {
  text-shadow: 0 0 10px rgba(183,28,28,0.5), 0 0 30px rgba(183,28,28,0.2);
}

/* Pixel border divider */
.pixel-divider {
  height: 4px;
  background: repeating-linear-gradient(
    90deg,
    #5D4037 0px, #5D4037 4px,
    transparent 4px, transparent 8px
  );
}

/* Stability bar */
.stability-bar {
  height: 12px;
  background: #212121;
  border: 2px solid #424242;
  overflow: hidden;
}
.stability-fill {
  height: 100%;
  transition: width 1s ease;
}

/* Tooltip Minecraft style */
.mc-tooltip {
  position: relative;
}
.mc-tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(16,0,16,0.94);
  color: #BDBDBD;
  font-size: 12px;
  padding: 6px 10px;
  border: 2px solid #2D0052;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 100;
  font-family: 'IBM Plex Sans', sans-serif;
}
.mc-tooltip:hover::after {
  opacity: 1;
}

/* Hamburger */
.hamburger-line {
  width: 24px;
  height: 3px;
  background: #E0E0E0;
  transition: all 0.3s ease;
}

/* Step timeline */
.step-line {
  width: 3px;
  background: repeating-linear-gradient(
    180deg,
    #5D4037 0px, #5D4037 6px,
    transparent 6px, transparent 12px
  );
}

/* Stat card shimmer */
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
.stat-shimmer {
  background: linear-gradient(90deg, transparent 0%, rgba(255,214,0,0.05) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: shimmer 3s infinite;
}

/* Mobile menu slide */
.mobile-menu {
  transform: translateX(100%);
  transition: transform 0.3s ease;
}
.mobile-menu.open {
  transform: translateX(0);
}

/* Nav scroll */
.nav-scrolled {
  background: rgba(44,24,16,0.95) !important;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

/* Badge ribbon */
.badge-ribbon {
  position: absolute;
  top: 16px;
  right: -8px;
  padding: 4px 16px 4px 12px;
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  letter-spacing: 1px;
  z-index: 5;
}
.badge-ribbon::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: -8px;
  width: 0;
  height: 0;
  border-style: solid;
}

.badge-gold {
  background: linear-gradient(90deg, #F9A825, #FFD600);
  color: #2C1810;
}
.badge-gold::after {
  border-width: 0 8px 8px 0;
  border-color: transparent #E65100 transparent transparent;
}

.badge-bronze {
  background: linear-gradient(90deg, #5D4037, #795548);
  color: #D7CCC8;
}
.badge-bronze::after {
  border-width: 0 8px 8px 0;
  border-color: transparent #3E2723 transparent transparent;
}

.badge-red {
  background: linear-gradient(90deg, #B71C1C, #E53935);
  color: #FFCDD2;
}
.badge-red::after {
  border-width: 0 8px 8px 0;
  border-color: transparent #7F0000 transparent transparent;
}

/* Tab styling */
.tab-btn {
  padding: 10px 20px;
  border: 2px solid #5D4037;
  background: rgba(44,24,16,0.8);
  color: #9E9E9E;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 600;
}
.tab-btn:hover {
  background: rgba(62,39,35,0.8);
  color: #E0E0E0;
}
.tab-btn.active {
  background: rgba(93,64,55,0.6);
  border-color: #FFD600;
  color: #FFD600;
}

/* Community card */
.community-card {
  border: 3px solid #5D4037;
  background: linear-gradient(180deg, rgba(62,39,35,0.7) 0%, rgba(44,24,16,0.9) 100%);
  transition: all 0.3s ease;
}
.community-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}

/* Pulse animation for gold download button */
@keyframes goldPulse {
  0%, 100% { box-shadow: inset 0 -3px 0 #E65100, inset 0 3px 0 #FFF176, 0 0 20px rgba(255,214,0,0.3); }
  50% { box-shadow: inset 0 -3px 0 #E65100, inset 0 3px 0 #FFF176, 0 0 35px rgba(255,214,0,0.5); }
}
.mc-btn-gold-pulse {
  animation: goldPulse 2s ease infinite;
}

/* Creator letter */
.creator-letter {
  background: linear-gradient(180deg, #D7CCC8 0%, #BCAAA4 100%);
  color: #3E2723;
  border: 3px solid #8D6E63;
  box-shadow: 4px 4px 0 rgba(0,0,0,0.3);
  font-family: 'IBM Plex Sans', sans-serif;
}

@media (max-width: 768px) {
  .badge-ribbon {
    font-size: 7px;
    padding: 3px 12px 3px 8px;
  }
}