body {
  margin: 0;
  font-family: "Trebuchet MS", Arial, sans-serif;
  transition: background-color 0.3s, color 0.3s;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}


body {
  background-color: #f0f0f0;
  color: #222;
}


header, footer {
  text-align: center;
  padding: 1rem;
  color: white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
  transition: background 0.3s ease;
}

body.blue-theme header,
body.blue-theme footer {
  background: linear-gradient(90deg, #1a3d7c, #2959a8);
}


body.purple-theme header,
body.purple-theme footer {
  background: linear-gradient(90deg, #4b0082, #800080);
}

header h1 {
  margin: 0.2rem 0;
  font-size: 2rem;
  letter-spacing: 2px;
}

.controls {
  margin-top: 0.5rem;
}

#themeToggle, #bgColorPicker {
  margin: 0.3rem;
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}

#themeToggle {
  background: #e63946;
  color: white;
  font-weight: bold;
}

#bgColorPicker {
  cursor: pointer;
  border: 2px solid #ccc;
  border-radius: 6px;
  padding: 0;
  height: 40px;
  width: 50px;
}


.grid-container {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  padding: 1.5rem;
}


.card {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 280px;
  border-radius: 16px;
  background-size: cover;
  background-position: center;
  box-shadow: 0 6px 18px rgba(0,0,0,0.6);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  text-align: center;
}

.card h2 {
  background: rgba(0,0,0,0.65);
  color: #fff;
  padding: 0.7rem 1rem;
  border-radius: 10px;
  font-size: 1.2rem;
  font-weight: bold;
}

.card:hover {
  transform: scale(1.07);
  box-shadow: 0 8px 22px rgba(0,0,0,0.8);
}

/* Era images */
.card[data-era="showa"] {
  background-image: url("Showa godzilla.jpeg");
}
.card[data-era="heisei"] {
  background-image: url("Heisei Godzilla.jpg");
}
.card[data-era="millennium"] {
  background-image: url("Millennium godzilla.webp");
}
.card[data-era="reiwa"] {
  background-image: url("Reiwa Godzilla.jpg");
}


footer {
  font-size: 1.2rem;
  letter-spacing: 1px;
  font-weight: bold;
}


@media (max-width: 768px) {
  header h1 {
    font-size: 1.6rem;
  }
  .card {
    height: 200px;
  }
}

@media (max-width: 480px) {
  .grid-container {
    grid-template-columns: 1fr;
  }
  .card {
    height: 160px;
  }
  footer {
    font-size: 1rem;
  }
}

.card.playing {
  border: 4px solid #39ff14;                
  box-shadow: 0 0 25px #39ff14;
  animation: pulseGreen 1.5s infinite;
}

.card.paused {
  border: 4px solid #ff2d2d;                 
  box-shadow: 0 0 25px #ff2d2d;
  animation: pulseRed 0.8s ease-in-out 3;    
}

@keyframes pulseGreen {
  0%   { box-shadow: 0 0 15px #39ff14; }
  50%  { box-shadow: 0 0 35px #39ff14; }
  100% { box-shadow: 0 0 15px #39ff14; }
}

@keyframes pulseRed {
  0%   { box-shadow: 0 0 10px #ff2d2d; }
  50%  { box-shadow: 0 0 30px #ff2d2d; }
  100% { box-shadow: 0 0 10px #ff2d2d; }
}









