:root {
  --primary: #0b3d91;
  --primary-dark: #082c68;
  --accent: #16a34a;
  --warning: #f59e0b;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --text: #172033;
  --muted: #667085;
  --border: #d8e0ec;
  --shadow: 0 16px 40px rgba(11, 61, 145, 0.10);
  --radius: 18px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

a { color: inherit; }

img { max-width: 100%; }

main {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 56px;
}

.navbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(11, 61, 145, 0.96);
  backdrop-filter: blur(10px);
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 14px max(24px, calc((100vw - 1120px) / 2));
  box-shadow: 0 8px 30px rgba(3, 18, 45, 0.18);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}

.logo-img {
  height: 42px;
  width: 42px;
  object-fit: contain;
  border-radius: 10px;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
  font-weight: 650;
  padding: 9px 12px;
  border-radius: 999px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  background: rgba(255,255,255,0.16);
}

.hero {
  width: min(1120px, calc(100% - 32px));
  margin: 34px auto 0;
  background:
    radial-gradient(circle at top left, rgba(22, 163, 74, 0.18), transparent 34%),
    linear-gradient(135deg, #eaf3ff 0%, #ffffff 55%, #eefdf4 100%);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: clamp(34px, 6vw, 72px);
  text-align: center;
  box-shadow: var(--shadow);
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1.02;
  max-width: 900px;
  margin: 0 auto 16px;
  letter-spacing: -0.06em;
}

.hero p {
  max-width: 720px;
  margin: 0 auto 24px;
  color: var(--muted);
  font-size: 1.1rem;
}

.search-container {
  position: relative;
  max-width: 640px;
  margin: 0 auto 24px;
}

.search-container input,
.input,
.review-form input,
.review-form textarea,
.review-form select {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  font-size: 1rem;
  background: #fff;
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-container input { padding-right: 48px; }

.search-container input:focus,
.input:focus,
.review-form input:focus,
.review-form textarea:focus,
.review-form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(11, 61, 145, 0.12);
}

.search-container::after {
  content: '🔍';
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.hero-map {
  width: 100%;
  height: 420px;
  margin-top: 24px;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.12);
}

.page-header {
  display: grid;
  gap: 12px;
  margin-bottom: 24px;
}

.page-header h1,
.card h1,
main > h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
  margin: 0;
  letter-spacing: -0.04em;
}

.page-header p { max-width: 740px; }

.muted { color: var(--muted); }

.card,
.review-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(20px, 3vw, 30px);
}

.landlord-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.landlord-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 10px 25px rgba(16, 24, 40, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.landlord-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.landlord-card h3 { margin: 12px 0 4px; font-size: 1.35rem; }

.card-topline,
.review-header,
.category-label,
.rating-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  background: #eaf3ff;
  color: var(--primary);
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.78rem;
}

.review-count { color: var(--muted); font-size: 0.9rem; }

.rating-row { justify-content: flex-start; margin: 12px 0; }
.rating-row.large { font-size: 1.25rem; }
.rating-number { font-size: 1.7rem; font-weight: 900; color: var(--primary); }
.stars { color: #f6b800; letter-spacing: 1px; white-space: nowrap; }

.button-link,
button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
  padding: 12px 18px;
  border: 0;
  border-radius: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.button-link:hover,
button:hover { background: var(--primary-dark); transform: translateY(-1px); }

.back-link { color: var(--primary); font-weight: 800; text-decoration: none; }

.profile-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 22px;
}

.profile-actions { display: grid; gap: 14px; min-width: 220px; }

.score-box {
  background: #f0fdf4;
  color: #14532d;
  border: 1px solid #bbf7d0;
  border-radius: 18px;
  padding: 18px;
  text-align: center;
}

.score-box strong { display: block; font-size: 2rem; line-height: 1; }
.score-box span { font-weight: 700; font-size: 0.9rem; }

.grid-two {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 22px;
  margin-bottom: 22px;
}

.category-row { margin: 16px 0; }
.category-label { font-weight: 750; margin-bottom: 7px; }
.bar { height: 10px; background: #edf2f7; border-radius: 999px; overflow: hidden; }
.bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: inherit; }

.check-list { padding-left: 20px; color: var(--muted); }
.check-list li { margin-bottom: 10px; }

.reviews-list { display: grid; gap: 16px; }
.review-card {
  border: 1px solid var(--border);
  background: #fbfdff;
  border-radius: 16px;
  padding: 18px;
}
.review-card h3 { margin: 0; }
.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pros-cons > div { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 14px; }
.pros-cons p { margin-bottom: 0; }

.review-form { max-width: 760px; margin: 0 auto; }
.review-form h2 { text-align: center; margin-top: 0; }
.review-form form { display: grid; gap: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-section-title { margin: 14px 0 0; font-weight: 900; color: var(--primary); }

.star-rating {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: 5px;
  font-size: 1.8rem;
  cursor: pointer;
}
.star { color: #d0d5dd; transition: color 0.2s; }
.star.selected,
.star:hover,
.star:hover ~ .star { color: #f6b800; }

.notice {
  background: #eef6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a8a;
  padding: 14px 16px;
  border-radius: 14px;
}
.notice.error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

.content-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 42px);
}
.content-card h2 { color: var(--primary); margin-top: 26px; }
.About_me_lookout { max-width: 900px; }
.family_pic { width: 220px; height: 220px; object-fit: cover; border-radius: 22px; box-shadow: var(--shadow); }
.Main_about_me { font-size: 1.1rem; font-weight: 650; }

.site-footer {
  background: var(--primary-dark);
  color: #fff;
  padding: 34px 16px 18px;
  font-size: 0.95rem;
}
.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  max-width: 1120px;
  margin: 0 auto;
  gap: 22px;
}
.footer-nav { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 14px; }
.footer-nav a,
.footer-contact a,
.footer-legal a { color: #fff; }
.footer-contact { text-align: right; }
.social-icons { display: flex; gap: 10px; justify-content: flex-end; }
.social-icon { width: 24px; height: 24px; object-fit: contain; }
.footer-legal { width: 100%; text-align: center; margin-top: 8px; }
.footer-copy { text-align: center; margin-top: 18px; border-top: 1px solid rgba(255,255,255,0.22); padding-top: 14px; color: rgba(255,255,255,0.82); }

@media (max-width: 780px) {
  .navbar { align-items: flex-start; flex-direction: column; }
  .nav-links { justify-content: flex-start; }
  .profile-hero { align-items: stretch; flex-direction: column; }
  .grid-two,
  .form-grid,
  .pros-cons { grid-template-columns: 1fr; }
  .footer-contact { text-align: left; }
  .social-icons { justify-content: flex-start; }
  .hero-map { height: 320px; }
}


.admin-panel { max-width: 1040px; margin: 0 auto; }
.card-soft {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
}
.admin-login {
  display: grid;
  grid-template-columns: 1fr 1fr auto auto;
  gap: 12px;
  align-items: center;
  margin-top: 18px;
}
.admin-warning code {
  background: rgba(255,255,255,0.75);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 6px;
}
.admin-rating-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 14px 0;
  color: var(--muted);
}
.admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.button-danger {
  background: #991b1b;
}
.button-danger:hover { background: #7f1d1d; }

@media (max-width: 780px) {
  .admin-login,
  .admin-rating-grid { grid-template-columns: 1fr; }
}


/* Admin dashboard tabs */
.admin-tabs {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 1.5rem 0;
  border-bottom: 1px solid #d6e0ef;
}

.admin-tab {
  border: 0;
  background: #eef5ff;
  color: #0b3b82;
  font-weight: 800;
  padding: 0.85rem 1.1rem;
  border-radius: 12px 12px 0 0;
  cursor: pointer;
}

.admin-tab.active {
  background: #174a99;
  color: #fff;
}

.admin-tab-panel {
  display: none;
}

.admin-tab-panel.active {
  display: block;
}

.compact-form {
  max-width: 720px;
  margin-left: 0;
}

.notice.success {
  background: #ecfdf3;
  border-color: #b7efc5;
  color: #075e2b;
}


/* Review form existing-landlord lock */
.selected-landlord-box {
  border: 1px solid #c7dcff;
  background: #f5f9ff;
  border-radius: 16px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.selected-landlord-box h2 {
  margin: 0.15rem 0;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 800;
  color: #174a99;
}

.small-link {
  display: inline-block;
  margin-top: 0.4rem;
  font-weight: 700;
}
