/* ── WEATHER SECTION WRAPPER ── */
.weather-section-wrapper {
  padding: 7rem 0;
  background: var(--light);
  position: relative;
  overflow: hidden;
}
.weather-section-wrapper::before {
  content: '';
  position: absolute;
  top: -200px; left: 50%;
  transform: translateX(-50%);
  width: 800px; height: 400px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(46,204,113,0.07), transparent 70%);
  pointer-events: none;
}
.weather-inner {
  max-width: 800px;
  margin: 0 auto;
}

/* SELECTOR */
.selector-card {
  background: var(--white);
  border-radius: 16px;
  padding: 2rem 2.4rem;
  border: 1.5px solid var(--mid);
  box-shadow: 0 4px 24px rgba(11,31,58,0.07);
  margin-bottom: 2rem;
}
.selector-card h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.2rem; font-weight: 800;
  color: var(--navy); margin-bottom: .4rem;
}
.selector-card p {
  font-size: .88rem; color: var(--muted);
  margin-bottom: 1.4rem;
}
.selector-row {
  display: flex; gap: 1rem; align-items: center; flex-wrap: wrap;
}
select {
  flex: 1; min-width: 200px;
  padding: 12px 16px;
  border: 1.5px solid var(--mid);
  border-radius: 10px;
  font-family: 'Inter', sans-serif; font-size: .95rem;
  color: var(--text); background: var(--light);
  outline: none; cursor: pointer;
  transition: border-color .2s, box-shadow .2s;
}
select:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(46,204,113,0.12);
}
.btn-fetch {
  padding: 12px 32px;
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  border: none; border-radius: 10px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700; font-size: .85rem;
  letter-spacing: .06em; color: #fff;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(11,31,58,0.25);
  transition: all .25s;
  display: flex; align-items: center; gap: 8px;
}
.btn-fetch:hover {
  background: linear-gradient(135deg, var(--green), var(--green2));
  box-shadow: 0 8px 24px rgba(46,204,113,0.35);
  transform: translateY(-1px);
}
.btn-fetch:disabled {
  opacity: .6; cursor: not-allowed; transform: none;
}

/* LOADING */
#loading {
  display: none; text-align: center; padding: 3rem;
  color: var(--muted); font-size: .9rem;
}
.spinner {
  width: 40px; height: 40px; border-radius: 50%;
  border: 3px solid var(--mid);
  border-top-color: var(--green);
  animation: spin 0.8s linear infinite;
  margin: 0 auto 1rem;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ERROR */
#error-box {
  display: none;
  background: #fff0f0; border: 1.5px solid #fca5a5;
  border-radius: 12px; padding: 1.2rem 1.5rem;
  color: #b91c1c; font-size: .9rem; margin-bottom: 1.5rem;
}

/* RESULTS */
#results { display: none; }

.city-header {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1.8rem; flex-wrap: wrap;
}
.city-name {
  font-family: 'Montserrat', sans-serif;
  font-size: 2rem; font-weight: 800; color: var(--navy);
}
.city-coords {
  font-size: .78rem; color: var(--muted);
  background: var(--white); padding: 4px 12px;
  border-radius: 20px; border: 1px solid var(--mid);
}
.weather-desc-badge {
  padding: 6px 16px; border-radius: 20px;
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  color: #fff; font-size: .8rem; font-weight: 600;
  letter-spacing: .06em;
}

/* MAIN TEMP CARD */
.temp-card {
  background: linear-gradient(145deg, var(--navy), #0d3a6e);
  border-radius: 20px; padding: 2.4rem;
  display: flex; align-items: center; gap: 2rem;
  margin-bottom: 1.5rem; flex-wrap: wrap;
  position: relative; overflow: hidden;
}
.temp-card::before {
  content: ''; position: absolute; top: -60px; right: -60px;
  width: 200px; height: 200px; border-radius: 50%;
  background: radial-gradient(circle, rgba(46,204,113,0.15), transparent 70%);
}
.temp-main {
  font-family: 'Montserrat', sans-serif;
  font-size: 5rem; font-weight: 900; color: #fff;
  line-height: 1;
}
.temp-main span { font-size: 2.5rem; font-weight: 500; color: rgba(255,255,255,0.6); }
.temp-feels {
  font-size: .9rem; color: rgba(255,255,255,0.6);
  margin-bottom: .5rem;
}
.temp-feels strong { color: #fff; }
.weather-icon-big {
  font-size: 5rem; line-height: 1;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.3));
}
.pod-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 14px; border-radius: 20px;
  font-size: .78rem; font-weight: 700; letter-spacing: .08em;
  margin-top: .5rem;
}
.pod-d { background: rgba(255,220,50,0.2); color: #FFD700; border: 1px solid rgba(255,220,50,0.3); }
.pod-n { background: rgba(100,150,255,0.2); color: #93c5fd; border: 1px solid rgba(100,150,255,0.3); }

/* SUN TIMES */
.sun-bar {
  background: var(--white); border-radius: 14px;
  padding: 1.2rem 1.8rem; margin-bottom: 1.5rem;
  border: 1.5px solid var(--mid);
  display: flex; align-items: center; gap: 2rem; flex-wrap: wrap;
}
.sun-item { display: flex; align-items: center; gap: 10px; }
.sun-icon { font-size: 1.8rem; }
.sun-label { font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.sun-time { font-family: 'Montserrat', sans-serif; font-size: 1.15rem; font-weight: 800; color: var(--navy); }
.sun-divider { flex: 1; height: 1px; background: var(--mid); }

/* DATA GRID */
.data-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}
.data-card {
  background: var(--white);
  border-radius: 14px; padding: 1.5rem 1.4rem;
  border: 1.5px solid var(--mid);
  transition: all .25s;
  position: relative; overflow: hidden;
}
.data-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(11,31,58,0.1);
  border-color: rgba(46,204,113,0.3);
}
.data-card::after {
  content: ''; position: absolute;
  bottom: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--green), #A8E063);
  transform: scaleX(0); transform-origin: left;
  transition: transform .3s;
}
.data-card:hover::after { transform: scaleX(1); }
.data-icon { font-size: 1.8rem; margin-bottom: .7rem; }
.data-label {
  font-size: .7rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); margin-bottom: .3rem;
}
.data-value {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.6rem; font-weight: 800; color: var(--navy);
  line-height: 1;
}
.data-unit {
  font-size: .85rem; font-weight: 500;
  color: var(--muted); margin-left: 3px;
}
.data-desc { font-size: .78rem; color: var(--muted); margin-top: .3rem; }

/* Progress bars */
.cloud-bar-bg, .production-bar-bg, .wind-prod-bar-bg {
  height: 6px; border-radius: 3px;
  background: var(--light); overflow: hidden; margin-top: .5rem;
}
.cloud-bar-fill { height: 100%; border-radius: 3px; background: linear-gradient(90deg, #94a3b8, #64748b); }
.production-bar-fill, .wind-prod-bar-fill {
  height: 100%; border-radius: 3px;
  transition: width .6s ease, background .4s ease;
}

/* TIMESTAMP */
.timestamp {
  text-align: center; margin-top: 1.8rem;
  font-size: .75rem; color: var(--muted);
  letter-spacing: .06em;
}

/* RESPONSIVE */
@media (max-width: 600px) {
  .weather-inner { padding: 0; }
  .selector-card { padding: 1.4rem 1.2rem; }
  .selector-card h2 { font-size: 1rem; }
  .selector-row { flex-direction: column; align-items: stretch; }
  select { min-width: unset; width: 100%; }
  .btn-fetch { width: 100%; justify-content: center; }
  .temp-main { font-size: 3.5rem; }
  .weather-icon-big { font-size: 3.5rem; }
  .city-name { font-size: 1.5rem; }
  .temp-card { padding: 1.5rem; gap: 1.2rem; }
  .sun-bar { padding: 1rem 1.2rem; gap: 1rem; }
}
