body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('./img/vecteezy_cat-paw-seamless-pattern-background-dog-paw-seamless_35279334.svg') repeat;
  background-size: contain;
  opacity: 0.1;
  z-index: -1;
}


body {
  font-family: Arial, sans-serif;
  text-align: center;
  margin: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  margin: 0;
}

#landing {
  position: relative;
  min-height: 0vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#landing::before {
  content: "";
  position: absolute;
  top: 40%;
  left: 50%;  
  transform: translate(-50%, -60%);
  width: min(60vmin, 420px);
  aspect-ratio: 1 / 1;
  display: block;
  background: url('./img/vecteezy_one-line-art-of-cat-illustration-minimalist_16187416.svg') no-repeat center;
  background-size: contain;
  opacity: 0.9;
  z-index: -1;
}

h1 {
  font-size: clamp(1.5rem, 5vw, 3rem);
  white-space: normal;
  background-color: rgb(255, 255, 255);
  padding: 2px;
  border-radius: 16px;
}


#loadCatButton {
  width: 120px;
  height: 40px;
  padding: 0;
  cursor: pointer;
  font-size: 1rem;
  font-weight: bold;
  background: #ffb347; /* warm orange */
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s;
}

button.pop-up:hover {
  background: #ff9800;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

button.pop-up:active {
  transform: translateY(0);
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

#catContainer,
#metricsContainer {
  display: none; /* hidden by default */
}

#catContainer {
  justify-content: center;
  justify-self: center;
  align-items: flex-start;
  gap: 2rem;
  margin-top: 2rem;
  width: 80%;
  flex-wrap: wrap;
}

#catImage {
  flex: 1;
}

#catImage img{
  min-width: 250px;
  max-width: 400px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

@media (max-width: 768px) {
  #catContainer {
    flex-direction: column;
    align-items: center;
  }

  #catImage img {
    max-width: 100%;
    height: auto;
  }
}

#catInfo {
  min-width: 250px;
  text-align: left;
  max-width: 450px;
  flex: 1;
}

#mainMetrics {
  margin-top: 1rem;
}

#metricsContainer {
  margin-top: 2rem;
  width: 80%;
  justify-self: center;
}

.pop-up {
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.pill-meters {
  display: grid;
  gap: 10px;
}

.meter-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.meter-name {
  /* flex: 0 0 120px; - transferred to js*/
  text-transform: capitalize;
  font: 600 14px/1.3 system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #333;
  white-space: nowrap;
}

.meter-pill {
  position: relative;
  width: 100%;
  height: 12px;
  background: #f2f4f7;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .06);
}

.meter-fill {
  flex: 1;
  height: 100%;
  border-radius: 999px;
  transition: width .35s ease;
}

.meter-value {
  font: 600 12px/1 system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #555;
  min-width: 48px;
  text-align: right;
}

footer {
  bottom: 10px;
  font-size: 0.8rem;
  text-align: center;
  margin-top: 2rem;
  color: #666;
}
