:root {
  --primary-color: #2196F3;
  --danger-color: #f44336;
  --success-color: #4CAF50;
  --text-color: #333;
  --background-color: #f5f5f5;
  --modal-background: rgba(0, 0, 0, 0.5);
  --border-radius: 8px;
  --transition-speed: 0.3s;
  --font-family: 'Poppins', sans-serif;
}

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

body {
  font-family: var(--font-family);
  background-color: var(--background-color);
  color: var(--text-color);
  line-height: 1.6;
  height: 100vh;
  overflow: hidden;
}

.game-container {
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 20px;
}

/* Header and Navigation */
.game-header {
  margin-bottom: 20px;
  flex-shrink: 0;
}

.game-main {
  flex: 1;
  min-height: 0;
  position: relative;
}

.game-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: white;
  padding: 15px;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 100;
}

.nav-buttons {
  display: flex;
  gap: 10px;
}

.nav-button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: none;
  border-radius: var(--border-radius);
  background: var(--primary-color);
  color: white;
  cursor: pointer;
  transition: all var(--transition-speed);
  position: relative;
  z-index: 101;
}

.nav-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.4);
}

.nav-button img {
  width: 24px;
  height: 24px;
}

.coins-display {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: #FFD700;
  border-radius: var(--border-radius);
  font-weight: 600;
}

#coins {
  color: black;
  text-shadow: 1px 1px 1px white;
  font-family: var(--font-family);
  font-size: 1.2em;
}

/* Fish Tank */
.fish-tank {
  width: 100%;
  height: 100%;
  border-radius: var(--border-radius);
  background-image: url(images/tank_1.png);
  background-size: cover;
  background-position: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  position: relative;
  border: solid 1px rgba(0, 0, 0, 0.2);
}

.animated-overlay {
  width: 100%;
  height: 100%;
  background-image: url(images/tank_overlay.gif);
  opacity: 0.2;
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
}

/* Floating Income Indicator */
.floating-income {
  position: absolute;
  color: #FFD700;
  font-size: 14px;
  font-weight: 600;
  pointer-events: none;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.9);
  padding: 4px 8px;
  border-radius: 12px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  white-space: nowrap;
  transform: translateX(-50%);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.floating-income i {
  color: #FFD700;
  margin-left: 4px;
}

/* Fish Styles */
.fish {
  position: absolute;
  cursor: pointer;
  background-repeat: no-repeat !important;
  background-size: contain !important;
  background-position: center !important;
  transition: transform 0.3s ease-in-out;
  z-index: 2;
}

.fish.hybrid {
  z-index: 3;
}

.fish-image {
  position: relative;
  display: block;
  background-repeat: no-repeat !important;
  background-size: contain !important;
  background-position: center !important;
  margin: 0 auto;
  transition: transform 0.3s ease-in-out;
}

.fish.left,
.fish-image.left {
  transform: scaleX(1);
}

.fish.right,
.fish-image.right {
  transform: scaleX(-1);
}

/* Fish selector styles */
.fishSelect {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px;
  margin: 5px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid transparent;
}

.fishSelect:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.fishSelect .fish-name {
  margin-top: 5px;
  font-size: 14px;
  color: white;
  text-align: center;
}

.fishSelect .fish-price {
  font-size: 12px;
  color: gold;
  margin-top: 3px;
}

/* Rarity colors */
.fishSelect.common {
  border-color: #a8a8a8;
}

.fishSelect.uncommon {
  border-color: #1eff00;
}

.fishSelect.rare {
  border-color: #0070dd;
}

.fishSelect.epic {
  border-color: #a335ee;
}

.fishSelect.legendary {
  border-color: #ff8000;
}

.fishSelect.hybrid {
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.hybrid-indicator {
  position: absolute;
  top: 5px;
  right: 5px;
  color: gold;
  font-size: 14px;
}

/* Base fish styles */
[class*="fish"].fish,
[class*="fish"].fish-image {
  background-repeat: no-repeat !important;
  background-size: contain !important;
  background-position: center !important;
}

/* Individual fish types */
.goldfish {
  background-image: url(assets/fish/goldfish.png);
}

.clownfish {
  background-image: url(assets/fish/clownfish.png);
}

.crownfish {
  background-image: url(assets/fish/crownfish.png);
}

.neonfish {
  background-image: url(assets/fish/neonfish.png);
}

.bass {
  background-image: url(assets/fish/bass.png);
}

.marlin {
  background-image: url(assets/fish/marlin.png);
}

.starfish {
  background-image: url(assets/fish/starfish.png);
}

.jellyfish {
  background-image: url(assets/fish/jellyfish.png);
}

.betta_fish {
  background-image: url(assets/fish/betta_fish.png);
}

.blue_tang {
  background-image: url(assets/fish/blue_tang.png);
}

.pufferfish {
  background-image: url(assets/fish/pufferfish.png);
}

.moray_eel {
  background-image: url(assets/fish/moray_eel.png);
}

.neonfish_2 {
  background-image: url(assets/fish/neonfish_2.png);
}

.neonfish_3 {
  background-image: url(assets/fish/neonfish_3.png);
}

.anchovy {
  background-image: url(assets/fish/anchovy.png);
}

.european_anchovy {
  background-image: url(assets/fish/european_anchovy.png);
}

.sardine {
  background-image: url(assets/fish/sardine.png);
}

.yellow_perch {
  background-image: url(assets/fish/yellow_perch.png);
}

.bluegill {
  background-image: url(assets/fish/bluegill.png);
}

.atlantic_mackerel {
  background-image: url(assets/fish/atlantic_mackerel.png);
}

.bluefish {
  background-image: url(assets/fish/bluefish.png);
}

.smallmouth_bass {
  background-image: url(assets/fish/smallmouth_bass.png);
}

.largemouth_bass {
  background-image: url(assets/fish/largemouth_bass.png);
}

.black_dragonfish {
  background-image: url(assets/fish/black_dragonfish.png);
}

.sturgeon {
  background-image: url(assets/fish/sturgeon.png);
}

.oarfish {
  background-image: url(assets/fish/oarfish.png);
}

.giant_isopod {
  background-image: url(assets/fish/giant_isopod.png);
}

/* Hybrid fish styles - using base fish images with filters */
.golden_neon {
  background-image: url(assets/fish/neonfish.png);
  filter: sepia(1) hue-rotate(20deg) saturate(2) brightness(1.2);
}

.rainbow_neon {
  background-image: url(assets/fish/neonfish.png);
  animation: rainbow 5s linear infinite;
}

.crystal_star {
  background-image: url(assets/fish/starfish.png);
  filter: hue-rotate(180deg) brightness(1.2);
  opacity: 0.8;
}

.royal_clown {
  background-image: url(assets/fish/clownfish.png);
  filter: hue-rotate(60deg) saturate(1.5);
}

.royal_betta {
  background-image: url(assets/fish/betta_fish.png);
  filter: hue-rotate(180deg) saturate(2) brightness(1.2);
}

.giant_bass {
  background-image: url(assets/fish/bass.png);
  filter: brightness(1.3) contrast(1.2);
}

.dragon_eel {
  background-image: url(assets/fish/moray_eel.png);
  filter: hue-rotate(120deg) saturate(2) brightness(1.2);
  animation: glow 2s ease-in-out infinite;
}

.spiky_puffer {
  background-image: url(assets/fish/pufferfish.png);
  filter: hue-rotate(30deg) saturate(1.5) brightness(1.1);
}

.crystal_betta {
  background-image: url(assets/fish/betta_fish.png);
  filter: hue-rotate(180deg) saturate(0.5) brightness(1.4) opacity(0.8);
  animation: crystal-shimmer 3s ease-in-out infinite;
}

.ghost_marlin {
  background-image: url(assets/fish/marlin.png);
  filter: saturate(0) brightness(1.5) opacity(0.7);
  animation: ghost-fade 4s ease-in-out infinite;
}

.prismatic_tang {
  background-image: url(assets/fish/blue_tang.png);
  filter: hue-rotate(30deg) saturate(1.5) brightness(1.1);
  animation: prismatic 6s linear infinite;
}

.void_isopod {
  background-image: url(assets/fish/giant_isopod.png);
  filter: invert(1) hue-rotate(180deg) brightness(0.7);
  animation: void-pulse 3s ease-in-out infinite;
}

.golden_sturgeon {
  background-image: url(assets/fish/sturgeon.png);
  filter: sepia(1) saturate(2) brightness(1.3);
  animation: golden-shimmer 2s ease-in-out infinite;
}

.plasma_jellyfish {
  background-image: url(assets/fish/jellyfish.png);
  filter: hue-rotate(90deg) saturate(2) brightness(1.3);
  animation: plasma-glow 3s ease-in-out infinite;
}

.fish:hover {
  opacity: 0.8;
}

.right {
  transform: scaleX(-1);
  transform-origin: center;
  margin-left: 0;
}

/* Counter the scaleX(-1) transform for text elements when fish faces right */
.right .fishName,
.right .growth,
.right .hunger-indicator,
.right .breeding-indicator,
.right .status-tooltip,
.right .feeding-effects,
.right .bonus-tooltip,
.right .active-bonus {
  transform: scaleX(-1);
  transform-origin: center;
}

/* Additional positioning fixes for specific elements */
.right .status-tooltip {
  transform-origin: center;
  transform: scaleX(-1) translateX(50%);
}

.right .breeding-indicator {
  transform-origin: center;
  transform: scaleX(-1) translateX(50%);
}

.right .active-bonus {
  transform-origin: left center;
  transform: scaleX(-1) translateX(0);
}

.right .bonus-tooltip {
  transform-origin: left center;
  transform: scaleX(-1) translateX(0);
}

.fishName {
  position: absolute;
  width: 200%;
  text-align: center;
  left: -50%;
  top: 120%;
  font-size: 12px;
  color: white;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.8);
  pointer-events: none;
  font-family: var(--font-family);
}

.growth {
  display: block;
  margin-top: 2px;
  width: 40px;
  height: 4px;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 2px;
  overflow: hidden;
  position: absolute;
  top: -20px;
  left: 0;
}

.inner_growth {
  background-color: var(--success-color);
  height: 100%;
  border-radius: 2px;
  transition: width var(--transition-speed);
}

.inner_growth.nearly-grown {
  background-color: #FFD700;
  animation: pulse-growth 2s infinite;
}

@keyframes pulse-growth {
  0% {
    opacity: 0.6;
  }

  50% {
    opacity: 1;
  }

  100% {
    opacity: 0.6;
  }
}

.hunger-indicator {
  display: block;
  width: 40px;
  height: 4px;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 2px;
  overflow: hidden;
  position: absolute;
  top: -26px;
  left: 0;
}

.hunger-indicator .inner-hunger {
  height: 100%;
  background-color: #FF9800;
  border-radius: 2px;
  transition: width var(--transition-speed);
}

.hunger-indicator .inner-hunger.warning {
  background-color: var(--danger-color);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--modal-background);
  z-index: 1000;
  opacity: 0;
  transition: opacity var(--transition-speed);
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

.modal-content {
  background-color: #ffffff;
  margin: auto;
  padding: 0;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  width: 80%;
  max-width: 800px;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1001;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.modal-header {
  padding: 15px 20px;
  border-bottom: 1px solid #e0e0e0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f8f9fa;
  border-radius: 8px 8px 0 0;
}

.modal-header h2 {
  margin: 0;
  font-size: 1.5em;
  color: #333;
}

.close-modal {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color var(--transition-speed);
}

.close-modal:hover {
  background-color: rgba(0, 0, 0, 0.1);
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  max-height: calc(90vh - 70px);
}

/* Fish Grid */
.fish-grid-container {
  padding: 10px;
  border-radius: 8px;
  background-color: #f8f9fa;
  border: 1px solid #e0e0e0;
}

.fish-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 12px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.fish-grid li {
  background: #ffffff;
  padding: 10px;
  border-radius: var(--border-radius);
  text-align: center;
  cursor: pointer;
  transition: transform var(--transition-speed);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-height: 120px;
  border: 1px solid #e0e0e0;
  position: relative;
}

.fish-grid li:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.fish-grid li .fish-image {
  width: 100%;
  height: 60px;
  background-size: contain !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  margin: 5px 0;
}

.fish-grid li .fish-name {
  font-size: 12px;
  color: #333;
  margin: 5px 0;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
  text-align: center;
}

/* Fish Stats */
.fish-stats {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.stats-section {
  background: #f8f9fa;
  border-radius: var(--border-radius);
  padding: 16px;
  border: 1px solid #e0e0e0;
}

.stats-section h3 {
  margin: 0 0 12px 0;
  font-size: 1.1em;
  color: #333;
  padding-bottom: 8px;
  border-bottom: 1px solid #e0e0e0;
}

.stat-row {
  display: flex;
  align-items: center;
  padding: 8px 0;
  gap: 12px;
}

.stat-row label {
  font-weight: 500;
  color: #666;
  min-width: 120px;
}

.stat-row span {
  color: #333;
  min-width: 80px;
}

.breeding-partners {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 1;
}

.breeding-partner {
  background: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #e0e0e0;
  font-size: 0.9em;
  display: flex;
  align-items: center;
  gap: 4px;
}

.breeding-partner.available {
  border-color: var(--success-color);
  background: rgba(76, 175, 80, 0.1);
}

.breeding-partner i {
  font-size: 12px;
}

.breeding-partner.available i {
  color: var(--success-color);
}

#stat_breeding_cooldown {
  color: var(--danger-color);
}

#stat_breeding_cooldown.ready {
  color: var(--success-color);
}

/* Progress Bars */
.growth-bar,
.hunger-bar {
  flex: 1;
  height: 6px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 3px;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.growth-progress,
.hunger-progress {
  height: 100%;
  transition: width var(--transition-speed);
  border-radius: 3px;
  background: linear-gradient(to right, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0)) var(--success-color);
}

.growth-progress {
  background-color: var(--success-color);
}

.hunger-progress {
  background-color: #FF9800;
}

.hunger-progress.warning {
  background-color: var(--danger-color);
}

/* Add subtle animation for nearly grown fish */
.growth-progress.nearly-grown {
  background: linear-gradient(to right, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0)) #FFD700;
  animation: progress-pulse 2s infinite;
}

@keyframes progress-pulse {
  0% {
    opacity: 0.8;
  }

  50% {
    opacity: 1;
  }

  100% {
    opacity: 0.8;
  }
}

/* Buttons */
.button {
  padding: 8px 16px;
  border: none;
  border-radius: var(--border-radius);
  background: var(--primary-color);
  color: white;
  cursor: pointer;
  transition: all var(--transition-speed);
  font-family: var(--font-family);
  font-size: 14px;
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.button.danger {
  background: var(--danger-color);
}

/* Toast Notifications */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  padding: 16px 24px;
  background: white;
  border-radius: var(--border-radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(100px);
  opacity: 0;
  transition: all var(--transition-speed);
  z-index: 2000;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast.error {
  background: var(--danger-color);
  color: white;
}

.toast.success {
  background: var(--success-color);
  color: white;
}

/* Decoration Sprites */
.small_plant {
  background-image: url(decorations/small_plant.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.golden_statue {
  background-image: url(decorations/golden_statue.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: sepia(0.5) hue-rotate(20deg) saturate(2) brightness(1.2);
}

.pearl_fountain {
  background-image: url(decorations/pearl_fountain.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: brightness(1.2) saturate(0.8);
}

.market_booth {
  background-image: url(decorations/market_booth.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.coral_formation {
  background-image: url(decorations/coral_formation.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: saturate(1.2) brightness(1.1);
}

.auto_feeder {
  background-image: url(decorations/auto_feeder.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  position: relative;
}

.auto_feeder .attraction-zone {
  position: absolute;
  border: 2px dashed rgba(76, 175, 80, 0.3);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}

.auto_feeder:hover .attraction-zone {
  opacity: 0.6;
}

.auto_feeder.feeding-active {
  animation: feeder-pulse 1s ease-in-out;
}

.feeding-effects {
  position: absolute;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  font-size: 12px;
  color: #4CAF50;
  pointer-events: none;
  white-space: nowrap;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  z-index: 1000;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.feeding-effects.active {
  opacity: 1;
  animation: feeding-float 1.5s ease-out;
}

@keyframes feeding-float {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(0);
  }

  20% {
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
}

.large_plant {
  background-image: url(decorations/large_plant.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.rock_cave {
  background-image: url(decorations/rock_cave.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.castle {
  background-image: url(decorations/castle.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.treasure_chest {
  background-image: url(decorations/treasure_chest.png);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

/* Rarity Indicators */
.fish::before {
  content: '';
  position: absolute;
  top: -5px;
  left: -5px;
  right: -5px;
  bottom: -5px;
  border-radius: 50%;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.fish:hover::before {
  opacity: 0.3;
}

.fish[data-rarity="common"]::before {
  box-shadow: 0 0 10px #ffffff;
}

.fish[data-rarity="uncommon"]::before {
  box-shadow: 0 0 10px #1eff00;
}

.fish[data-rarity="rare"]::before {
  box-shadow: 0 0 15px #0070dd;
}

.fish[data-rarity="epic"]::before {
  box-shadow: 0 0 20px #a335ee;
}

.fish[data-rarity="legendary"]::before {
  box-shadow: 0 0 25px #ff8000;
  animation: legendary-pulse 2s infinite;
}

@keyframes legendary-pulse {
  0% {
    opacity: 0.2;
    transform: scale(1);
  }

  50% {
    opacity: 0.4;
    transform: scale(1.1);
  }

  100% {
    opacity: 0.2;
    transform: scale(1);
  }
}

/* Fish name color based on rarity */
.fish[data-rarity="uncommon"] .fishName {
  color: #1eff00;
}

.fish[data-rarity="rare"] .fishName {
  color: #0070dd;
}

.fish[data-rarity="epic"] .fishName {
  color: #a335ee;
}

.fish[data-rarity="legendary"] .fishName {
  color: #ff8000;
  text-shadow: 0 0 5px rgba(255, 128, 0, 0.5);
}

.hidden {
  display: none !important;
}

/* Input Form */
.input-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-weight: 500;
  color: var(--text-color);
}

.form-input {
  padding: 10px 12px;
  border: 2px solid #e0e0e0;
  border-radius: var(--border-radius);
  font-family: var(--font-family);
  font-size: 16px;
  transition: border-color var(--transition-speed);
}

.form-input:focus {
  outline: none;
  border-color: var(--primary-color);
}

.form-input::placeholder {
  color: #999;
}

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

.button.outline {
  background: transparent;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
}

.button.outline:hover {
  background: rgba(33, 150, 243, 0.1);
}

/* Breeding Indicator */
.breeding-indicator {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 18px;
  animation: pulse-breeding 1s infinite;
  pointer-events: none;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
  z-index: 10;
}

@keyframes pulse-breeding {
  0% {
    transform: translateX(-50%) scale(1);
    filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
  }

  50% {
    transform: translateX(-50%) scale(1.3);
    filter: drop-shadow(0 0 4px rgba(255, 255, 255, 1));
  }

  100% {
    transform: translateX(-50%) scale(1);
    filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
  }
}

/* Decoration Grid Styles */
.decoration-grid-container {
  padding: 10px;
  border-radius: 8px;
  background-color: #f8f9fa;
  border: 1px solid #e0e0e0;
  margin-top: 16px;
}

.decoration-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 12px;
  padding: 16px;
}

.decoration-item {
  background: #ffffff;
  padding: 12px;
  border-radius: var(--border-radius);
  text-align: center;
  cursor: pointer;
  transition: transform var(--transition-speed);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  border: 1px solid #e0e0e0;
}

.decoration-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.decoration-preview {
  width: 60px;
  height: 60px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.decoration-info {
  width: 100%;
}

.decoration-name {
  font-size: 12px;
  color: #333;
  margin: 0;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

.decoration-price {
  color: #ffd700;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 4px;
}

.decoration-price i {
  color: #FFD700;
  font-size: 12px;
}

.decoration-bonuses {
  font-size: 11px;
  color: #4CAF50;
  margin-top: 4px;
  line-height: 1.3;
}

.decoration-filters {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.decoration-instructions {
  text-align: center;
  padding: 16px;
  background: #f8f9fa;
  border-radius: var(--border-radius);
  border: 1px solid #e0e0e0;
  margin-top: 16px;
  color: #666;
  font-size: 14px;
}

.decoration-instructions p {
  margin: 5px 0;
}

/* Category Filters */
.category-filter {
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  color: #333;
  padding: 8px 16px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
}

.category-filter:hover {
  background-color: #f0f0f0;
}

.category-filter.active {
  background-color: #4a9eff;
  color: #ffffff;
  border-color: #4a9eff;
}

/* Status Tooltips */
.status-tooltip {
  position: absolute;
  background: rgba(255, 255, 255, 0.95);
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  transform: translateX(-50%);
  z-index: 1000;
  pointer-events: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: tooltip-pop-up 0.3s ease-out;
}

.status-tooltip.warning {
  background: var(--danger-color);
  color: white;
}

.status-tooltip.success {
  background: var(--success-color);
  color: white;
}

.status-tooltip.info {
  background: var(--primary-color);
  color: white;
}

.status-tooltip.love {
  background: #FF69B4;
  color: white;
}

.status-tooltip.fade-out {
  opacity: 0;
  transform: translateX(-50%) translateY(-10px);
  transition: all 0.5s ease-out;
}

@keyframes tooltip-pop-up {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(5px);
  }

  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Remove the old fully-grown-indicator styles and add new halo effect */
.fish.fully-grown::after {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.3) 0%, rgba(255, 215, 0, 0) 70%);
  animation: fully-grown-pulse 2s ease-in-out infinite;
  pointer-events: none;
  z-index: -1;
}

@keyframes fully-grown-pulse {
  0% {
    transform: scale(0.95);
    opacity: 0.5;
  }

  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }

  100% {
    transform: scale(0.95);
    opacity: 0.5;
  }
}

/* Counter the scaleX(-1) transform for the halo when fish faces right */
.fish.right.fully-grown::after {
  transform-origin: center;
  transform: scaleX(-1);
  animation: fully-grown-pulse-right 2s ease-in-out infinite;
}

@keyframes fully-grown-pulse-right {
  0% {
    transform: scaleX(-1) scale(0.95);
    opacity: 0.5;
  }

  50% {
    transform: scaleX(-1) scale(1.05);
    opacity: 0.8;
  }

  100% {
    transform: scaleX(-1) scale(0.95);
    opacity: 0.5;
  }
}

.decoration {
  position: absolute;
  z-index: 2;
  transition: transform 0.2s;
  user-select: none;
  touch-action: none;
}

.decoration:hover {
  transform: scale(1.05);
}

.decoration .bonus-area {
  position: absolute;
  border: 1px dashed rgba(76, 175, 80, 0.3);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.decoration:hover .bonus-area {
  opacity: 1;
}

.decoration[data-draggable="true"] {
  cursor: grab;
}

.decoration[data-draggable="true"]:active {
  cursor: grabbing;
}

.decoration .sell-button {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 24px;
  height: 24px;
  background: var(--danger-color);
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 3;
}

.decoration:hover .sell-button {
  opacity: 1;
}

.decoration .sell-button:hover {
  transform: scale(1.1);
  background: #d32f2f;
}

/* Bonus Tooltips */
.bonus-tooltip {
  position: absolute;
  background: rgba(255, 255, 255, 0.95);
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  transform: translateX(-50%);
  z-index: 1000;
  pointer-events: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: tooltip-pop-up 0.3s ease-out;
  color: var(--success-color);
  top: -30px;
  left: 50%;
}

.bonus-tooltip.active {
  opacity: 1;
  visibility: visible;
}

.right .bonus-tooltip {
  transform-origin: left center;
  transform: scaleX(-1) translateX(0);
}

/* New Animations */

@keyframes rainbow {
  0% {
    filter: hue-rotate(0deg);
  }

  100% {
    filter: hue-rotate(360deg);
  }
}

@keyframes crystal-shimmer {

  0%,
  100% {
    filter: hue-rotate(180deg) saturate(0.5) brightness(1.4) opacity(0.8);
  }

  50% {
    filter: hue-rotate(200deg) saturate(0.7) brightness(1.6) opacity(0.9);
  }
}

@keyframes ghost-fade {

  0%,
  100% {
    filter: saturate(0) brightness(1.5) opacity(0.7);
  }

  50% {
    filter: saturate(0) brightness(1.7) opacity(0.4);
  }
}

@keyframes prismatic {
  0% {
    filter: hue-rotate(0deg) saturate(2) brightness(1.2);
  }

  100% {
    filter: hue-rotate(360deg) saturate(2) brightness(1.2);
  }
}

@keyframes void-pulse {

  0%,
  100% {
    filter: invert(1) hue-rotate(180deg) brightness(0.7);
  }

  50% {
    filter: invert(1) hue-rotate(200deg) brightness(0.9);
  }
}

@keyframes golden-shimmer {

  0%,
  100% {
    filter: sepia(1) saturate(2) brightness(1.3);
  }

  50% {
    filter: sepia(1) saturate(2.5) brightness(1.5);
  }
}

@keyframes plasma-glow {

  0%,
  100% {
    filter: hue-rotate(90deg) saturate(2) brightness(1.3);
  }

  50% {
    filter: hue-rotate(120deg) saturate(2.5) brightness(1.5);
  }
}

@keyframes glow {

  0%,
  100% {
    filter: hue-rotate(120deg) saturate(2) brightness(1.2);
  }

  50% {
    filter: hue-rotate(140deg) saturate(2.5) brightness(1.4);
  }
}

.fish-image {
  position: relative;
  background-repeat: no-repeat !important;
  background-size: contain !important;
  background-position: center !important;
  width: 100%;
  height: 40px;
}