/* styles.css - moderne, responsiv layout */

/* Reset */
* {box-sizing: border-box;}
html,body {height:100%; margin:0; font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif; color:#fff;}

/* Background image */
body {
  background-image: url('https://images.unsplash.com/photo-1506744038136-46273834b3fb?auto=format&fit=crop&w=1920&q=80');
  background-size: cover;
  background-position: center;
  display: flex;
  min-height: 100vh;
}

/* dark overlay for readability */
.overlay {
  position: fixed; inset:0; background: rgba(4,12,20,0.55); z-index:0;
}

/* Sidebar */
#sidebar {
  position: relative;
  z-index:2;
  width: 240px;
  min-width: 180px;
  background: linear-gradient(180deg, rgba(0,0,0,0.65), rgba(0,0,0,0.55));
  padding: 28px 18px;
  display: flex;
  flex-direction: column;
  gap:12px;
  border-right: 1px solid rgba(255,255,255,0.04);
}

.brand h1 {font-size:18px; color:#9be7ff; margin-bottom:4px;}
nav ul {list-style:none; padding:0; margin-top:6px;}
nav li {margin:6px 0;}
nav a {
  display:block;
  padding:10px 12px;
  color:#eaf6ff;
  text-decoration:none;
  border-radius:8px;
  transition: all .22s ease;
}
nav a:hover, nav a:focus {
  transform: translateX(6px);
  background: rgba(155,231,255,0.12);
  color:#c0f0ff;
  outline:none;
}

/* Sidebar footer */
.sidebar-footer {margin-top:auto; font-size:12px; color:rgba(255,255,255,0.6);}

/* Main content */
#content {
  flex:1;
  z-index:1;
  padding: 28px;
  overflow:auto;
  min-width:0;
}

/* Topbar and weather box */
.topbar {
  display:flex;
  justify-content:flex-end;
  gap:20px;
  align-items:center;
  margin-bottom:18px;
}

.weather-box {
  background: rgba(255,255,255,0.06);
  padding:10px 14px;
  border-radius:10px;
  min-width:140px;
  text-align:center;
  backdrop-filter: blur(4px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.35);
}
.weather-box .wb-title {font-size:12px; color: #dff8ff; margin-bottom:6px;}
.weather-box .wb-main {display:flex; gap:10px; align-items:center; justify-content:center;}
.wb-main #wb-temp {font-size:20px; font-weight:700;}
.wb-main #wb-desc {font-size:13px; opacity:0.95;}
.wb-meta {font-size:11px; margin-top:6px; opacity:0.85;}

/* Hero */
.hero h2 {font-size:28px; margin-bottom:8px;}
.hero p {max-width:720px; line-height:1.6; margin-bottom:16px; color: #e6f7ff;}

.card {
  margin-top:18px;
  background: rgba(255,255,255,0.04);
  padding:14px;
  border-radius:10px;
  border: 1px solid rgba(255,255,255,0.03);
  max-width:760px;
}

/* Modal / login popup */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 20;
  padding: 20px;
}
.modal[aria-hidden="false"] { display:flex; }

.modal-content {
  width: 100%;
  max-width: 380px;
  background: #fff;
  color: #111;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 10px 36px rgba(2,6,23,0.6);
  position: relative;
}

.close {
  position: absolute;
  top:10px;
  right:12px;
  background:transparent;
  border:0;
  font-size:22px;
  cursor:pointer;
}

.modal-content h2 {margin-top:2px; margin-bottom:12px;}
.modal-content label {display:block; font-size:13px; margin-top:8px;}
.modal-content input[type="text"],
.modal-content input[type="password"] {
  width:100%; padding:10px; margin-top:6px; border:1px solid #ddd; border-radius:8px;
}
.btn {
  margin-top:12px;
  width:100%;
  padding:10px;
  border-radius:8px;
  border:0;
  background: linear-gradient(90deg,#00c6ff,#0077b6);
  color:#001;
  font-weight:700;
  cursor:pointer;
}

/* Error */
.error {color:#b00020; margin-top:8px; font-size:13px;}

/* Responsive */
@media (max-width:800px) {
  #sidebar {position:fixed; left:0; top:0; bottom:0; transform: translateX(0); width:200px;}
  #content {padding:18px;}
  .topbar {justify-content:flex-start;}
}
@media (max-width:520px) {
  #sidebar {width:68px;}
  nav a {padding:10px 8px; font-size:13px;}
  .weather-box {min-width:110px; padding:8px;}
}
