/* Weather Widget Container */
.fyplugins-weather-widget {
  background: linear-gradient(135deg, #74b9ff 0%, #0984e3 100%);
  color: white;
  padding: 25px;
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  max-width: 350px;
  margin: 20px auto;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  position: relative;
  overflow: hidden;
}

.fyplugins-weather-widget::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 70%
  );
  pointer-events: none;
}

/* City Name */
.fyplugins-weather-city {
  margin: 0 0 20px 0;
  font-size: 24px;
  font-weight: 300;
  text-align: center;
  letter-spacing: 1px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Temperature Section */
.fyplugins-weather-temp {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
  position: relative;
  z-index: 1;
}

.fyplugins-weather-temp img {
  width: 80px;
  height: 80px;
  margin-right: 15px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.fyplugins-weather-temp .temperature {
  font-size: 48px;
  font-weight: 100;
  line-height: 1;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Weather Description */
.fyplugins-weather-description {
  text-align: center;
  font-size: 18px;
  margin-bottom: 20px;
  text-transform: capitalize;
  font-weight: 300;
  opacity: 0.9;
}

/* Weather Details */
.fyplugins-weather-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.15);
  padding: 15px;
  border-radius: 15px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Center single item when only one detail is shown */
.fyplugins-weather-details:has(span:only-child) {
  justify-content: center;
}

/* Fallback for browsers that don't support :has() */
.fyplugins-weather-details span:only-child {
  margin: 0 auto;
}

.fyplugins-weather-details span {
  font-size: 14px;
  font-weight: 400;
  opacity: 0.9;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.fyplugins-weather-details .humidity::before {
  content: "💧";
  font-size: 20px;
  margin-bottom: 5px;
}

.fyplugins-weather-details .wind::before {
  content: "🌬️";
  font-size: 20px;
  margin-bottom: 5px;
}

/* Error Styling */
.fyplugins-weather-error {
  background: #ff6b6b;
  color: white;
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
  max-width: 350px;
  margin: 20px auto;
}

/* Responsive Design */
@media (max-width: 480px) {
  .fyplugins-weather-widget {
    margin: 10px;
    padding: 20px;
    max-width: none;
  }

  .fyplugins-weather-temp {
    flex-direction: column;
    text-align: center;
  }

  .fyplugins-weather-temp img {
    margin-right: 0;
    margin-bottom: 10px;
  }

  .fyplugins-weather-details {
    flex-direction: column;
    gap: 15px;
  }
}

/* Dark theme variant */
.fyplugins-weather-widget.dark {
  background: linear-gradient(135deg, #2d3436 0%, #636e72 100%);
}

/* Light theme variant */
.fyplugins-weather-widget.light {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  color: #2d3436;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

.fyplugins-weather-widget.light .fyplugins-weather-details {
  background: rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

/* Animation */
.fyplugins-weather-widget {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
