:root {
  --sky-top: #477fbf;
  --sky-bottom: #73a8e2;
  --sky-overlay: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.06),
    rgba(16, 42, 76, 0.1) 56%,
    rgba(0, 0, 0, 0.05)
  );
  --sky-scene-opacity: 1;
  --card-fill-start: rgba(255, 255, 255, 0.19);
  --card-fill-end: rgba(255, 255, 255, 0.09);
  --card-border: rgba(255, 255, 255, 0.14);
}
.weather-app {
  background: linear-gradient(
    180deg,
    var(--sky-top),
    var(--sky-bottom) 55%,
    var(--sky-bottom)
  ) !important;
  transition: background 1.2s ease;
}
.sky-scene {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.1),
    transparent 42%,
    rgba(0, 0, 0, 0.08)
  );
  opacity: var(--sky-scene-opacity);
  transition: background 1s ease;
}
.sky-scene::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--sky-overlay);
  pointer-events: none;
}
.sun-glow {
  transition:
    opacity 1s ease,
    transform 1s ease;
}
.cloud {
  transition: opacity 1s ease;
}
.sky-scene[data-weather="clear"] .cloud {
  opacity: 0.22;
}
.sky-scene[data-weather="clear"] .sun-glow {
  opacity: 0.9;
}
.sky-scene[data-weather="cloud"] .sun-glow {
  opacity: 0.3;
}
.sky-scene[data-weather="cloud"] .cloud {
  opacity: 0.7;
}
.sky-scene[data-weather="rain"] .sun-glow,
.sky-scene[data-weather="storm"] .sun-glow {
  opacity: 0;
}
.sky-scene[data-weather="rain"] .cloud {
  opacity: 0.85;
}
.sky-scene[data-weather="storm"] .cloud {
  opacity: 1;
}
.sky-scene[data-weather="snow"] .sun-glow {
  opacity: 0.12;
}
.sky-scene[data-weather="fog"] .sun-glow {
  opacity: 0.08;
}
.sky-scene[data-weather="fog"] .haze {
  background: linear-gradient(
    180deg,
    rgba(240, 247, 250, 0.2),
    rgba(240, 247, 250, 0.32),
    rgba(240, 247, 250, 0.18)
  );
}
.weather-app:has(.sky-scene[data-weather="rain"]) {
  background-image: linear-gradient(
    180deg,
    var(--sky-top),
    var(--sky-bottom)
  ) !important;
}
.weather-app:has(.sky-scene[data-weather="storm"]) {
  background-image: linear-gradient(
    180deg,
    var(--sky-top),
    var(--sky-bottom)
  ) !important;
}
.weather-app:has(.sky-scene[data-weather="snow"]) {
  background-image: linear-gradient(
    180deg,
    var(--sky-top),
    var(--sky-bottom)
  ) !important;
}
.weather-app:has(.sky-scene[data-weather="fog"]) {
  background-image: linear-gradient(
    180deg,
    var(--sky-top),
    var(--sky-bottom)
  ) !important;
}
body[data-daynight="night"] .sun-glow {
  opacity: 0 !important;
}
body[data-daynight="night"] .sky-scene {
  background:
    radial-gradient(
      circle at 75% 18%,
      rgba(170, 205, 255, 0.12),
      transparent 16%
    ),
    linear-gradient(180deg, rgba(3, 15, 34, 0.2), rgba(0, 0, 0, 0.08));
}
.weather-app:after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(
      circle at 20% 20%,
      rgba(255, 255, 255, 0.35) 0 1px,
      transparent 1.5px
    ),
    radial-gradient(
      circle at 70% 30%,
      rgba(255, 255, 255, 0.25) 0 1px,
      transparent 1.5px
    ),
    radial-gradient(
      circle at 45% 15%,
      rgba(255, 255, 255, 0.2) 0 1px,
      transparent 1.5px
    );
  background-size:
    170px 150px,
    230px 190px,
    310px 240px;
  opacity: 0;
  transition: opacity 1s;
}
.weather-app:has(.sky-scene[data-weather="clear"])[data-night="true"]:after,
body[data-daynight="night"] .weather-app:after {
  opacity: 0.75;
}
