@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* =========================
   RESET + BASE
========================= */

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

html,
body {
  height: 100%;
  width: 100%;
  background: var(--bg-main);
  color: var(--text-primary);
}

/* =========================
   NAVBAR
========================= */

nav {
  height: 70px;
  padding: 0 2rem;
  background: var(--gradient-header);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

nav h1 {
  font-size: 1.25rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

nav h1 i {
  color: var(--accent-primary);
}

#themeBtn {
  background: var(--gradient-primary);
  color: white;
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  font-weight: 500;
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

#themeBtn:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

/* =========================
   TOP SECTION (WEATHER)
========================= */

#top {
  position: relative;
  height: 45vh;
  padding: 2.5rem;
}

#bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.55);
  z-index: 1;
}

#container {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  overflow: hidden;
}

#top::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
      rgba(0, 0, 0, 0.35),
      rgba(0, 0, 0, 0.7));
  z-index: -1;
}

/* LEFT SIDE */

#left {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

#date {
  font-size: 2rem;
  color: var(--text-secondary);
}

#time {
  font-size: 4rem;
  font-weight: 500;
}

#city {
  font-size: 2.2rem;
  font-weight: 700;
  margin-top: 0.5rem;
}

/* RIGHT SIDE */

#right {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 1.5rem 2rem;
  border-radius: 16px;
  min-width: 280px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

#temp {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-primary);
}

#other-details {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

/* =========================
   BOTTOM SECTION (TOOLS)
========================= */

#bottom {
  padding: 3rem 2rem;
}

#bottom ul {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

#bottom li a {
  cursor: pointer;
  text-decoration: none;
}

#bottom li {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 5rem 2rem;
  border-radius: 18px;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, border 0.25s ease;
}

#bottom li::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient-card-glow);
  opacity: 0;
  transition: opacity 0.25s ease;
}

#bottom li:hover {
  transform: translateY(-6px);
  border-color: var(--accent-primary);
}

#bottom li:hover::before {
  opacity: 1;
}

#bottom li h1 {
  position: relative;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 768px) {
  #container {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    overflow: visible;
  }


  #top {
    height: fit-content;
  }

  #right {
    width: 100%;
  }


  nav h1{ 
    font-size: 0.8rem;
  }

}