* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border: none;
  outline: none;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(135deg, #1e3c72, #2a5298);
  padding: 20px;
}

.container {
  width: 100%;
  max-width: 420px;
  height: min-content;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 30px 25px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.search-box {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.search-box input {
  width: 84%;
  font-size: 18px;
  text-transform: capitalize;
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
  padding: 12px 16px;
  border-radius: 14px;
  backdrop-filter: blur(4px);
  transition: background 0.3s;
}

.search-box input::placeholder {
  color: #ccc;
}

.search-box input:focus {
  background: rgba(255, 255, 255, 0.25);
}

.search-box button {
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, #a1c4fd, #c2e9fb);
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s;
}

.search-box button:hover {
  background: #85a7e8;
  color: #fff;
}

.weather-body {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
  gap: 20px;
  animation: fadeIn 0.4s ease-in-out;
}

.weather-body img {
  width: 120px;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
}

.weather-box {
  text-align: center;
  color: #fff;
}

.weather-box .temperature {
  font-size: 3.5rem;
  font-weight: 800;
  position: relative;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.weather-box .temperature sup {
  font-size: 1.5rem;
  position: absolute;
  font-weight: 600;
  top: 8px;
  right: -30px;
}

.weather-box .description {
  font-size: 1.2rem;
  font-weight: 600;
  text-transform: capitalize;
  color: #cbe6ff;
  letter-spacing: 0.05rem;
}

.weather-details {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  margin-top: 25px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 15px;
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.05);
}

.humidity,
.wind {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  color: #e7f4ff;
}

.weather-details i {
  font-size: 24px;
  color: #a9c9ff;
  transition: color 0.3s;
}

.weather-details i:hover {
  color: #ffd700;
}

.weather-details .text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.text span {
  font-size: 1.1rem;
  font-weight: 700;
}

.location-not-found {
  margin-top: 20px;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: #fff;
}

.location-not-found h1 {
  font-size: 1.2rem;
  color: #ffdddd;
  margin-bottom: 12px;
}

.location-not-found img {
  width: 70%;
  opacity: 0.8;
}

/* Optional Fade In Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Existing styles stay unchanged — now adding responsive adjustments */
@media (max-width: 480px) {
  .container {
    width: 100%;
    padding: 22px 15px;
    border-radius: 16px;
  }

  .search-box input {
    font-size: 16px;
    padding: 10px 14px;
  }

  .search-box button {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }

  .weather-body img {
    width: 100px;
  }

  .weather-box .temperature {
    font-size: 2.8rem;
  }

  .weather-box .temperature sup {
    font-size: 1rem;
    right: -24px;
  }

  .weather-box .description {
    font-size: 1rem;
  }

  .weather-details {
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 12px;
  }

  .humidity,
  .wind {
    justify-content: center;
    gap: 10px;
  }

  .weather-details .text span {
    font-size: 1rem;
  }

  .weather-details .text p {
    font-size: 0.9rem;
  }

  .location-not-found h1 {
    font-size: 1rem;
    text-align: center;
  }

  .location-not-found img {
    width: 90%;
  }
}
