body {
  font-family: "Comic Neue", "Segoe UI", sans-serif;
  margin: 0;
  padding: 20px;
  background: linear-gradient(135deg, #6dd5ed, #2193b0);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  color: #333;
}

.game-container {
  background: #fff;
  border-radius: 25px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  padding: 35px;
  text-align: center;
  width: 90%;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 25px;
  border: 4px solid #ffd166;
}

h1 {
  color: #ef476f;
  margin-bottom: 25px;
  font-size: 3em;
  text-shadow: 2px 2px 0px #ffdde1;
}

h2 {
  color: #118ab2;
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 1.8em;
  border-bottom: 3px dashed #06d6a0;
  padding-bottom: 5px;
  width: 100%;
}

.pet-display-area {
  margin-bottom: 20px;
}

#pet-image {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  border: 6px solid #ffd166;
  object-fit: cover;
  box-shadow: 0 0 20px rgba(239, 71, 111, 0.6);
  transition: transform 0.3s ease-in-out;
}
#pet-image:hover {
  transform: rotate(5deg) scale(1.1);
}

.pet-name {
  font-size: 2em;
  font-weight: bold;
  color: #073b4c;
  margin-top: 15px;
}

.status-section {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.status-bar-group {
  width: 90%;
  display: flex;
  align-items: center;
  gap: 10px;
}
.status-bar-group label {
  font-weight: bold;
  color: #073b4c;
  min-width: 90px;
}

.bar-container {
  flex-grow: 1;
  background-color: #e0e0e0;
  border-radius: 15px;
  height: 22px;
  overflow: hidden;
  position: relative;
  border: 2px solid #bbb;
}

.status-bar {
  height: 100%;
  width: 100%;
  transition: width 0.5s ease-out;
  border-radius: 15px;
}

.status-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-weight: bold;
  font-size: 0.85em;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
}

.hunger-bar {
  background: linear-gradient(90deg, #ff9f1c, #ffbf69);
}
.happiness-bar {
  background: linear-gradient(90deg, #06d6a0, #1b998b);
}
.energy-bar {
  background: linear-gradient(90deg, #118ab2, #073b4c);
}
.hygiene-bar {
  background: linear-gradient(90deg, #9b5de5, #f15bb5);
}

.action-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}
.action-button {
  background: linear-gradient(135deg, #ef476f, #ff6b6b);
  color: white;
  border: none;
  padding: 14px 28px;
  border-radius: 50px;
  cursor: pointer;
  font-size: 1.1em;
  font-weight: bold;
  transition: transform 0.2s ease, box-shadow 0.3s ease;
  box-shadow: 0 6px 12px rgba(239, 71, 111, 0.3);
}
.action-button:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 16px rgba(239, 71, 111, 0.4);
}
.action-button:active {
  transform: scale(0.95);
}
.action-button:disabled {
  background: #aaa;
  cursor: not-allowed;
  box-shadow: none;
}

.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  justify-content: center;
  align-items: center;
}
.modal-content {
  background: #fff;
  padding: 30px;
  border-radius: 15px;
  width: 80%;
  max-width: 400px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
  text-align: center;
}
.modal-content p {
  font-size: 1.2em;
  color: #333;
}
.modal-content .action-button {
  background: linear-gradient(135deg, #118ab2, #06d6a0);
  padding: 10px 25px;
  font-size: 1em;
}

@media (max-width: 600px) {
  .game-container {
    padding: 20px;
    width: 95%;
  }
  h1{
    font-size: 2.2em;
  }
  h2{
    font-size: 1.6em;
  }
  #pet-image {
    width: 150px;
    height: 150px;
  }
  .pet-name {
    font-size: 1.5em;
  }
  .status-bar-group {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }
  .status-bar-group label {
    text-align: left;
    width: 100%;
  }
  .bar-container {
    width: 100%;
  }
  .action-button{
    width: 100%;
    padding: 10px 15px;
    font-size: 1em;
  }
  .modal-content {
    width: 90%;
    padding: 20px;
  }
}
