* {
  margin: 0;
  padding: 0;
  font-family: "Poppins", sans-serif;
  box-sizing: border-box;
}

body {
  /*background: #fff;*/
  background: url("Assets/Giff/backgrouding.gif");
  background-repeat: no-repeat;
  background-size: cover;
  background-position: left;
  min-height: 100vh;
}

/* Search box */
.group {
  display: flex;
  align-items: center;
  position: relative;
  max-width: 90%;
  margin: 20px auto;
}

.input {
  font-family: "Montserrat", sans-serif;
  width: 100%;
  height: 45px;
  padding-left: 2.5rem;
  padding-right: 30px;
  box-shadow: 0 0 0 1.5px #2b2c37, 0 0 25px -17px #000;
  border: 0;
  border-radius: 12px;
  background-color: #16171d;
  outline: none;
  color: #bdbecb;
  transition: all 0.25s cubic-bezier(0.19, 1, 0.22, 1);
  cursor: text;
  z-index: 0;
}

.input::placeholder {
  color: #bdbecb;
}

.input:hover {
  box-shadow: 0 0 0 2.5px #2f303d, 0px 0px 25px -15px #000;
}

.input:focus {
  box-shadow: 0 0 0 2.5px #2f303d;
}

.icon {
  position: absolute;
  left: 1rem;
  fill: #bdbecb;
  width: 1rem;
  height: 1rem;
  pointer-events: none;
  z-index: 1;
}

button {
  width: 100px;
  height: 45px;
  cursor: pointer;
  color: #fff;
  font-size: 14px;
  border-radius: 50px;
  border: none;
  position: absolute;
  background-color: #16171d;
  right: 0;
  top: 0;
  transition: 0.1s;
}

button:active {
  transform: scale(0.9) rotate(3deg);
}

/* Card container */
.card {
  width: 90%;
  max-width: 400px;
  background: #fff;
  border-radius: 1rem;
  box-shadow: rgba(50, 50, 93, 0.25) 0px 6px 12px -2px,
    rgba(0, 0, 0, 0.3) 0px 3px 7px -3px;
  margin: 40px auto;
  padding: 20px;
  text-align: center;
  position: relative;
  color: #000;
}

.weather_icon {
  width: 100px;
  max-width: 40%;
  margin: 10px auto;
}

.weather h2 {
  font-size: 36px;
  font-weight: 100;
  margin-top: 10px;
}

.weather h3 {
  font-size: 28px;
  margin-top: 5px;
  font-family: "Gill Sans", "Gill Sans MT", Calibri, "Trebuchet MS", sans-serif;
}

.details,
.details1 {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  margin-top: 20px;
}

.col,
.col_1,
.col_2 {
  display: flex;
  align-items: center;
  margin: 10px;
}

.col img,
.col_1 img,
.col_2 img {
  width: 50px; /*40px*/
  margin-right: 10px;
}

.max,
.min,
.humidity,
.wind {
  font-size: 20px;
  margin-top: -4px;
}

/* Time card */
.card3 {
  width: auto;
  padding: 10px 15px;
  border-radius: 15px;
  background: #fff;
  box-shadow: rgba(0, 0, 0, 0.1) 0px 2px 5px;
  display: flex;
  flex-direction: column;
  text-align: center;
  position: relative;
  margin: 20px auto;
}

/* Time text */
.time-text {
  font-size: 20px;
  font-weight: 600;
  margin: 0;
}

.time-sub-text {
  font-size: 14px;
  margin-left: 5px;
}

.day-text {
  font-size: 16px;
  font-weight: 500;
  margin-top: 5px;
}

/* Error message */
.Error_Occur {
  text-align: center;
  color: #ff0000;
  font-size: 14px;
  margin-top: 10px;
  display: none;
}

/* Responsive media queries */
@media (max-width: 768px) {
  .card {
    padding: 15px;
  }
  .weather h2 {
    font-size: 28px;
  }
  .weather h3 {
    font-size: 22px;
  }
  .weather_icon {
    width: 80px;
  }
  .col img,
  .col_1 img,
  .col_2 img {
    width: 40px;
  }
  .max,
  .min,
  .humidity,
  .wind {
    font-size: 16px;
  }
  .group {
    margin: 10px auto;
  }
}

@media (max-width: 480px) {
  .weather h2 {
    font-size: 24px;
  }
  .weather h3 {
    font-size: 18px;
  }
  .weather_icon {
    width: 70px;
  }
  .col img,
  .col_1 img,
  .col_2 img {
    width: 25px;
  }
  .max,
  .min,
  .humidity,
  .wind {
    font-size: 14px;
  }
  .card3 {
    padding: 8px;
  }
}

/*New code*/
.details1 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 20px;
  padding: 0 10px;
  flex-wrap: wrap; /* ensures it won’t overflow on small screens */
}

.col_1,
.col_2 {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 120px; /* prevents shrinking too much */
  background: #f9f9f9;
  border-radius: 10px;
  padding: 8px 12px;
  box-sizing: border-box; /* keeps padding inside container */
}

.col_1 img,
.col_2 img {
  width: 35px;
  height: 35px;
  margin-right: 8px;
}

.max,
.min {
  font-size: 18px;
  font-weight: bold;
  margin: 0;
  color: #333;
}

.max_,
.min_ {
  font-size: 13px;
  color: #666;
  margin-top: 2px;
}

/* 📱 Extra safety for very small screens (300–400px) */
@media (max-width: 400px) {
  .details1 {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }

  .col_1,
  .col_2 {
    justify-content: flex-start;
    width: 100%;
  }
}
