:root {
  --primary-color: #002f5a;
  --secondary-color: #004e8a;
  --accent-color: #ff0000;
  --text-light: #ffffff;
  --text-dim: #e0e0e0;
  --glass-bg: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.2);
  --gradient-overlay: linear-gradient(
    180deg,
    rgba(0, 47, 90, 0.6) 0%,
    rgba(0, 47, 90, 0.8) 100%
  );
  --font-main: "Outfit", sans-serif;
  --shadow-glow: 0 0 20px rgba(255, 0, 0, 0.3);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background-color: #002f5a;
  color: var(--text-light);
  line-height: 1.6;
  overflow-x: hidden;
  user-select: none; /* Prevent text selection */
  -webkit-user-select: none;
}

/* Utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: var(--accent-color);
  padding: 12px 30px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 1px solid var(--accent-color);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background-color: var(--accent-color);
  transition: width 0.3s ease;
  z-index: -1;
}

.btn-primary:hover {
  color: var(--primary-color);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover::before {
  width: 100%;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: var(--text-light);
  padding: 12px 30px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 1px solid var(--text-light);
  margin-left: 15px;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-secondary::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background-color: var(--text-light);
  transition: width 0.3s ease;
  z-index: -1;
}

.btn-secondary:hover {
  color: var(--primary-color);
  border-color: var(--text-light);
  transform: translateY(-3px);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover::before {
  width: 100%;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1100; /* Above overlay */
  padding: 20px 0;
  transition: all 0.3s ease;
  background: rgba(0, 47, 90, 0.85);
  border-bottom: 1px solid transparent; /* Prepare for border on scroll */
}

.navbar.scrolled {
  background: rgba(0, 47, 90, 0.98);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
  padding: 12px 0;
  border-bottom: 1px solid var(--glass-border); /* Sharp definition on scroll */
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-light);
  font-weight: 700;
  font-size: 1.5rem;
}

.logo img {
  height: 40px;
  margin-right: 10px;
}

.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
}

.nav-links li {
  margin-left: 30px;
}

.nav-links a:not(.btn-primary) {
  color: var(--text-light);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:not(.btn-primary):hover {
  color: var(--accent-color);
}

.hamburger {
  display: none;
  cursor: pointer;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 30px;
  height: 2px;
  background-color: var(--accent-color);
  margin: 6px 0;
  transition: all 0.3s ease;
}

/* Mobile Menu */
@media (max-width: 768px) {
  .hamburger {
    display: block;
    position: relative;
    z-index: 1002;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    max-width: 80%;
    height: 100vh;
    background-color: var(--primary-color);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
    z-index: 1005; /* Higher than overlay */
    padding: 20px;
    border-left: 1px solid var(--glass-border);
  }

  .nav-links.active {
    right: 0;
  }

  /* Overlay for mobile menu */
  .menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 47, 90, 0.7); /* Themed semi-transparent overlay */
    z-index: 1004; /* Below nav-links but above content */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }

  .menu-overlay.active {
    opacity: 1;
    visibility: visible;
  }

  .nav-links li {
    margin: 15px 0;
    width: 100%;
    text-align: center;
  }

  .nav-links a {
    font-size: 1.3rem;
    display: block;
    padding: 12px 20px;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  }

  .nav-links .btn-primary {
    display: flex;
    width: fit-content;
    margin: 10px auto;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
  }
}

#hero-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.hero {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero-content h1 {
  font-size: 4rem;
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero-content .highlight {
  color: var(--accent-color);
  background: linear-gradient(to right, var(--accent-color) 0%, #00f2fe 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 30px rgba(255, 0, 0, 0.3);
}

.hero-content p {
  font-size: 1.2rem;
  color: var(--text-dim);
  margin-bottom: 40px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 15px;
}

@media (max-width: 768px) {
  .hero-content h1 {
    font-size: 2.5rem;
    padding: 0 20px;
  }

  .hero-content p {
    font-size: 1rem;
    margin-bottom: 30px;
  }

  .hero-btns {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
  }

  .btn-primary,
  .btn-secondary {
    width: 80%;
    max-width: 300px;
    margin: 0;
  }
}

/* Sections */
.section {
  padding: 100px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 15px;
}

.section-header .line {
  width: 80px;
  height: 4px;
  background: var(--accent-color);
  margin: 0 auto;
  border-radius: 2px;
}

/* About Section */
.about-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: 4px;
  padding: 40px;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px -15px rgba(0, 0, 0, 0.3);
}

.glass-card:hover {
  transform: translateY(-7px);
  border-color: var(--accent-color);
  box-shadow: var(--shadow-glow);
}

.about-card .icon {
  font-size: 3rem;
  margin-bottom: 20px;
  color: var(--accent-color);
}

.about-card h3 {
  font-size: 1.5rem;
  margin-bottom: 15px;
  color: var(--text-light);
}

/* Collection Section */
.collection-section {
  background: transparent;
}

.tiktok-showcase {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.tiktok-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  color: var(--accent-color);
  padding: 15px 30px;
  border-radius: 4px;
  text-decoration: none;
  margin-top: 20px;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 1px solid var(--accent-color);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.tiktok-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background-color: var(--accent-color);
  transition: width 0.3s ease;
  z-index: -1;
}

.tiktok-btn:hover {
  color: var(--primary-color);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.tiktok-btn:hover::before {
  width: 100%;
}

/* Contact Section */
.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  text-align: left;
}

.contact-info h3,
.contact-cta h3 {
  font-size: 1.8rem;
  margin-bottom: 20px;
  color: var(--text-light);
}

.contact-list {
  list-style: none;
  margin-top: 30px;
}

.contact-list li {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  font-size: 1.1rem;
}

.contact-list .icon {
  margin-right: 15px;
  font-size: 1.5rem;
  color: var(--accent-color);
}

.contact-list a {
  color: var(--text-light);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-list a:hover {
  color: var(--accent-color);
}

/* Footer */
.footer {
  background: transparent;
  padding: 40px 0;
  text-align: center;
  border-top: 1px solid var(--glass-border);
}

.footer-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-weight: 700;
  font-size: 1.2rem;
}

.footer-logo img {
  height: 30px;
  margin-right: 10px;
}

.copyright {
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 {
  transition-delay: 0.2s;
}
.delay-2 {
  transition-delay: 0.4s;
}

/* Responsive */
@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .glass-card {
    padding: 25px;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .contact-info,
  .contact-cta {
    text-align: center;
  }

  .contact-list li {
    justify-content: center;
  }

  #feeding-widget {
    bottom: 15px;
    right: 15px;
    left: 15px;
    padding: 10px 20px;
    gap: 10px;
    justify-content: space-between;
    border-radius: 12px;
  }

  #feeding-widget .label {
    display: none;
  }

  .coin-display {
    padding-left: 10px;
    font-size: 1rem;
  }

  #badge-btn {
    top: auto;
    bottom: 85px;
    left: auto;
    right: 20px;
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }

  #active-gadgets-hud {
    top: auto;
    bottom: 150px;
    right: 20px;
    left: auto;
  }

  #decoration-toolbar {
    bottom: 80px;
    left: 15px;
    right: 15px;
    width: auto;
    max-height: none; /* Removed height constraint */
    overflow-y: visible;
    padding-bottom: 20px;
  }

  .shop-panel {
    grid-template-columns: repeat(2, 1fr);
  }
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
  100% {
    transform: translateY(0px);
  }
}

.hero-content h1 {
  animation: float 6s ease-in-out infinite;
}

#feeding-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  padding: 15px 25px;
  display: flex;
  align-items: center;
  gap: 15px;
  z-index: 1000;
  border-radius: 50px;
  background: rgba(0, 47, 90, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

#feeding-widget .icon {
  color: var(--accent-color);
  font-size: 1.2rem;
}

#feeding-widget .info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

#feeding-widget .label {
  font-size: 0.8rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}

#feeding-widget .count {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-light);
}

#feeding-widget.unlocked {
  border-color: #ffd700;
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

#feeding-widget.unlocked .icon {
  color: #ffd700;
}

#feeding-widget .next-unlock {
  font-size: 0.7rem;
  color: var(--accent-color);
  margin-top: 2px;
}

.coin-display {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #ffd700;
  font-weight: 700;
  font-size: 1.1rem;
  border-left: 1px solid rgba(255, 255, 255, 0.2);
  padding-left: 15px;
}

.decorate-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--text-light);
  color: var(--text-light);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-left: 10px;
}

.decorate-btn:hover {
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--primary-color);
  transform: scale(1.1);
}

.decorate-btn.active {
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--primary-color);
  box-shadow: 0 0 15px var(--accent-color);
}

#decoration-toolbar {
  position: fixed;
  bottom: 140px; /* Moved up to avoid overlap */
  right: 20px;
  padding: 15px;
  display: flex;
  gap: 10px;
  z-index: 1000;
  border-radius: 12px;
  background: rgba(0, 47, 90, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
}

.shop-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 10px 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  color: var(--text-light);
  min-width: 100px;
}

.shop-item:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.shop-item.active {
  border-color: #ffd700;
  background: rgba(255, 215, 0, 0.1);
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
}

.shop-item .name {
  font-size: 0.9rem;
  font-weight: 600;
}

.shop-item .cost {
  font-size: 0.8rem;
  color: #ffd700;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Gadget Timer */
.gadget-timer {
  position: absolute;
  bottom: 5px;
  right: 5px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 5px;
  border-radius: 4px;
  font-weight: bold;
  pointer-events: none;
}

/* Badge Button */
#badge-btn {
  position: fixed;
  top: 100px;
  left: 20px;
  z-index: 1000;
}

/* Active Gadgets HUD */
#active-gadgets-hud {
  position: fixed;
  top: 160px;
  left: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 900;
  pointer-events: none; /* Let clicks pass through */
}

.hud-gadget-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: slideIn 0.3s ease forwards;
}

.hud-gadget-item.circular {
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}

.progress-ring {
  position: relative;
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.progress-ring svg {
  transform: rotate(-90deg);
}

.progress-ring__circle {
  transition: stroke-dashoffset 0.1s linear;
  transform-origin: 50% 50%;
}

.hud-gadget-item .icon {
  position: absolute;
  color: #fff;
  font-size: 1.2rem;
  z-index: 1;
}

.timer-overlay {
  position: absolute;
  bottom: -5px;
  background: rgba(0, 0, 0, 0.7);
  color: #ffd700;
  font-size: 0.7rem;
  padding: 1px 4px;
  border-radius: 4px;
  font-weight: bold;
  font-family: monospace;
}

.hud-gadget-item.fade-out {
  animation: fadeOut 0.3s ease forwards;
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: rgba(0, 47, 90, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-left: 4px solid var(--accent-color);
  padding: 15px 20px;
  border-radius: 4px;
  color: var(--text-light);
  min-width: 250px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  animation: slideIn 0.3s ease forwards;
  display: flex;
  align-items: center;
  gap: 10px;
}

.toast.success {
  border-left-color: #00ff88;
}

.toast.error {
  border-left-color: #ff4444;
}

.toast.fade-out {
  animation: fadeOut 0.3s ease forwards;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

/* Achievement Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3000;
  backdrop-filter: blur(5px);
  animation: fadeIn 0.3s ease forwards;
}

.modal-content {
  background: rgba(0, 47, 90, 0.95);
  border: 1px solid var(--accent-color);
  padding: 40px;
  border-radius: 16px;
  text-align: center;
  max-width: 400px;
  width: 90%;
  box-shadow: 0 0 50px rgba(255, 0, 0, 0.3);
  transform: scale(0.8);
  opacity: 0;
  animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.modal-icon {
  font-size: 4rem;
  color: #ffd700;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
  animation: float 3s ease-in-out infinite;
}

#modal-title {
  font-size: 2rem;
  color: var(--text-light);
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 2px;
}

#modal-desc {
  font-size: 1.2rem;
  color: var(--text-dim);
  margin: 0;
}

#modal-close-btn {
  margin-top: 10px;
  font-size: 1.2rem;
  padding: 15px 40px;
  cursor: pointer;
}

/* Immersive Mode */
body.immersive-mode .navbar,
body.immersive-mode .hero-content,
body.immersive-mode .section,
body.immersive-mode .footer {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes popIn {
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Shop Tabs */
.shop-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: 10px;
}

.tab-btn {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  cursor: pointer;
  padding: 5px 10px;
  transition: all 0.3s ease;
}

.tab-btn.active {
  color: var(--accent-color);
  text-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

.shop-panel {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.shop-panel.active {
  display: grid;
}

/* Gadget Item */
.gadget-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  min-width: 80px;
  transition: all 0.3s ease;
}

.gadget-item:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.gadget-item.active {
  border-color: #ffd700;
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
}

.gadget-item.purchased {
  opacity: 0.5;
  filter: grayscale(1);
  cursor: not-allowed;
  pointer-events: none;
}

.gadget-item.purchased:hover {
  transform: none;
  background: rgba(255, 255, 255, 0.05);
}

.gadget-icon {
  font-size: 1.5rem;
  color: var(--accent-color);
}

.gadget-info {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gadget-name {
  font-size: 0.8rem;
  font-weight: 600;
}

.gadget-cost {
  font-size: 0.7rem;
  color: #ffd700;
}

/* Active Powerup Indicator */
.active-powerup {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 10px;
  height: 10px;
  background: #00ff00;
  border-radius: 50%;
  box-shadow: 0 0 5px #00ff00;
  display: none;
}

.gadget-item.active .active-powerup {
  display: block;
}

/* Disco Mode */
.disco-mode #hero-canvas {
  animation: disco-bg 2s infinite;
}

@keyframes disco-bg {
  0% {
    filter: hue-rotate(0deg);
  }
  100% {
    filter: hue-rotate(360deg);
  }
}
.badge-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 20px;
  width: 100%;
  max-height: 60vh;
  overflow-y: auto;
  padding: 10px;
}

.badge-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 20px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  position: relative;
  opacity: 0.5;
  filter: grayscale(1);
}

.badge-item.unlocked {
  opacity: 1;
  filter: grayscale(0);
  background: rgba(0, 47, 90, 0.6);
  border-color: #ffd700;
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
}

.badge-item.unlocked:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 25px rgba(255, 215, 0, 0.4);
}

.badge-icon {
  font-size: 2.5rem;
  color: var(--text-dim);
}

.badge-item.unlocked .badge-icon {
  color: #ffd700;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.badge-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-dim);
}

.badge-item.unlocked .badge-name {
  color: var(--text-light);
}

.badge-desc {
  font-size: 0.7rem;
  color: var(--text-dim);
  display: none; /* Hidden by default, shown on hover/click if needed, or just use title */
}

/* Badge Progress */
.badge-progress-bar {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 8px;
}

.badge-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #ff4444 0%, #ffaa00 50%, #00ff88 100%);
  border-radius: 2px;
  transition: width 0.3s ease;
  box-shadow: 0 0 8px rgba(0, 255, 136, 0.5);
}

.badge-progress-text {
  font-size: 0.7rem;
  color: #ffffff;
  margin-top: 5px;
  font-weight: 600;
  text-align: center;
}

/* Scrollbar for badge grid */
.badge-grid::-webkit-scrollbar {
  width: 8px;
}
.badge-grid::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
}
.badge-grid::-webkit-scrollbar-thumb {
  background: var(--accent-color);
  border-radius: 4px;
}
/* Loading Overlay */
#loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #002f5a;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#loading-overlay.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.loader-fish {
  font-size: 3rem;
  color: var(--accent-color);
  text-shadow: 0 0 20px rgba(255, 0, 0, 0.5);
}

.loader-text {
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-light);
  text-transform: uppercase;
}
