@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400..700;1,400..700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');


* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  min-height: 100vh;
  line-height: 1.5;
  font-family: 'Poppins', sans-serif;
  font-size: 100%;
  background: linear-gradient(135deg, #e0f7f4, #d0eeff);
}

img {
  display: block;
}

input, button, select, textarea {
  font: inherit;
}

ul, ol {
  list-style: none;
}

a {
  text-decoration: none;
  color: inherit;
}

h1 {
    font-family: 'Lora', sans-serif;
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.card-container {
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
}

.card {
  margin-top: 3rem;
  width: 840px;
  max-width: 90%;
  min-height: 570px;
  border-radius: 24px;
  background: linear-gradient(135deg, #e8f4fd 0%, #87ceeb 30%, #3b8fd4 65%, #57aee8 100%);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}

.input-container {
  display: flex;
  gap: 10px;
  margin-bottom: 28px;
}

.input-wrapper {
  position: relative;
  flex: 1;
}

.input-wrapper input {
  width: 100%;
  padding: 10px 18px;
  border-radius: 10px;
  border: none;
  background: rgba(255,255,255,0.92);
  font-size: 14px;
  color: #444;
  outline: none;
}

#dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  display: none;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.search-result {
  padding: 10px 18px;
  font-size: 14px;
  color: #444;
  cursor: pointer;
}

.search-result:hover {
  background: #f0f0f0;
}


#submit-button {
  padding: 10px 22px;
  border-radius: 10px;
  border: none;
  background: #2176ae;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.2s;
}

.top-row {
  margin: 0 auto;
  padding: 0 1rem;
}

.city-name {
  font-size: clamp(1.2rem, 4vw, 2.2rem);
  font-family: 'Lora', sans-serif;
  margin-bottom: 0.8rem;
}

.main-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  justify-items: center;
  margin-bottom: 32px;
}

.weather-icon-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 1.2rem;
}

.weather-icon-row img {
  height: clamp(80px, 15vw, 150px);
  width: clamp(80px, 15vw, 150px);
}

.temp-items {
  display: grid;
  grid-template-columns: 1fr;
}

.temp-degree {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.temp-degree div:last-child {
  font-size: 1.2rem;
  margin-bottom: 1.6rem;
}

.temp-display {
  font-family: 'Lora', sans-serif;
  font-weight: 200;
  font-size: 4.8rem;
}

.temp-bold-fah {
  cursor: pointer;
}

.temp-bold-cel {
  cursor: pointer;
}

.forecast-row {
  display: flex;
  justify-content: space-between;
  padding: 1.5rem 0;
  background: linear-gradient(180deg,rgba(255, 255, 255, 0.25) 0%,rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.1) 100%);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 15px;
}
 
.forecast-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}
 
.forecast-day .day-label {
  font-size: 1.3rem;
  font-weight: 500;
  text-transform: uppercase;
  font-family: 'Lora', sans-serif;
}

/* loader from css-loaders.com */

.loader {
  width: 50px;
  aspect-ratio: 1;
  --_c:no-repeat radial-gradient(farthest-side,#000 92%,#0000);
  background: 
    var(--_c) top,
    var(--_c) left,
    var(--_c) right,
    var(--_c) bottom;
  background-size: 12px 12px;
  animation: l7 1s infinite;
  display: none;
  margin: auto;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.show {
  display: block;
}

.alert {
  display: inline-block;
  padding: 0.5rem 1rem;
  color: #fff;
  background-color: #ff3333;
  border-radius: 4px;
  font-size: 1.4rem;
}

@keyframes l7 {to{transform: rotate(.5turn)}}