:root {
  --brand-primary: #2a7de1;
  --brand-secondary: #1bd8a6;
  --brand-dark: #1e2a3b;
  --brand-light: #f7f9fc;
  --text-muted: #6f7a85;
  --transition-base: all 0.3s ease;
  --card-radius: 18px;
  --shadow-lg: 0 18px 35px rgba(23, 52, 95, 0.1);
  --shadow-sm: 0 8px 20px rgba(23, 52, 95, 0.08);
  
  /* Light theme (default) */
  --bg-primary: #f7f9fc;
  --bg-secondary: #ffffff;
  --text-primary: #1e2a3b;
  --text-secondary: #6f7a85;
  --border-color: #e5e9f0;
  --card-bg: #ffffff;
  --navbar-bg: #ffffff;
  --footer-bg: #0f1724;
  --footer-text: rgba(255, 255, 255, 0.85);
}

html[data-theme="dark"] {
  /* Dark theme */
  --bg-primary: #0f1724;
  --bg-secondary: #1e293b;
  --text-primary: #f1f5f9;
  --text-secondary: #cbd5e1;
  --text-muted: #cbd5e1;
  --border-color: #334155;
  --card-bg: #1e293b;
  --navbar-bg: #1e293b;
  --footer-bg: #0a0f1a;
  --footer-text: rgba(255, 255, 255, 0.9);
  --brand-light: #1e293b;
  --shadow-lg: 0 18px 35px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 8px 20px rgba(0, 0, 0, 0.2);
}

html[data-theme="dark"] body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
}

html[data-theme="dark"] .navbar {
  background-color: var(--navbar-bg);
}

html[data-theme="dark"] .navbar-nav .nav-link {
  color: var(--text-primary);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  line-height: 1.65;
  font-size: 1rem;
  transition: background-color 0.3s ease, color 0.3s ease;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-base);
}

a:hover,
a:focus {
  color: var(--brand-primary);
}

section {
  padding: 4rem 0;
}

.section-heading {
  text-align: center;
  margin-bottom: 1rem;
}

.section-heading.text-lg-start {
  margin-bottom: 1.5rem;
}

.section-heading h2 {
  font-size: 2.25rem;
  font-weight: 600;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.section-heading h3 {
  font-size: 1.35rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.section-heading p {
  max-width: 620px;
  margin: 1rem auto 0;
  color: var(--text-muted);
}

.topbar {
  background-color: var(--brand-dark);
  color: #ffffff;
  font-size: 0.9rem;
}

.topbar .contact-info a {
  color: #ffffff;
  margin-right: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.topbar .social-links {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.topbar .social-links a {
  color: #ffffff;
  font-size: 1.1rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: var(--transition-base);
}

.topbar .social-links a:hover {
  color: var(--brand-secondary);
}

.navbar-brand img,
.navbar-brand svg {
  height: 42px;
  width: auto;
  display: block;
}

.navbar {
  padding: 0.85rem 0;
  background-color: var(--navbar-bg);
  box-shadow: 0 2px 14px rgba(20, 40, 80, 0.08);
  transition: background-color 0.3s ease;
}

.navbar-light .navbar-toggler {
  border: none;
}

.navbar-light .navbar-toggler:focus {
  box-shadow: 0 0 0 0.1rem rgba(42, 125, 225, 0.25);
}

.navbar-light .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(30, 42, 59, 0.8)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.navbar.navbar-scrolled {
  padding: 0.6rem 0;
  box-shadow: 0 12px 24px rgba(20, 40, 80, 0.12);
}

.navbar-nav .nav-link {
  padding: 0.75rem 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
  text-transform: capitalize;
  transition: color 0.3s ease;
}

.navbar-nav .nav-link.active,
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
  color: var(--brand-primary);
}

.btn {
  border-radius: 999px;
  font-weight: 600;
  padding: 0.75rem 1.75rem;
  transition: var(--transition-base);
}

.btn-brand {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
  color: #ffffff;
  border: none;
  box-shadow: var(--shadow-sm);
}

.btn-brand:hover,
.btn-brand:focus {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: #ffffff;
}

.btn-outline-brand {
  border: 2px solid var(--brand-primary);
  color: var(--brand-primary);
  background-color: transparent;
}

.btn-outline-brand:hover,
.btn-outline-brand:focus {
  background: var(--brand-primary);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.btn-outline-brand.active {
  background: var(--brand-primary);
  color: #ffffff;
}

.btn-brand.active {
  box-shadow: var(--shadow-lg);
}

.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.dropdown-item.active,
.dropdown-item:active {
  background-color: var(--brand-primary);
  color: #ffffff;
}

.hero {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, rgba(42, 125, 225, 0.1), rgba(27, 216, 166, 0.1));
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url("https://images.unsplash.com/photo-1505691938895-1758d7feb511?auto=format&fit=crop&w=2000&q=80") center/cover;
  opacity: 0.25;
  mix-blend-mode: multiply;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
}

.hero-content .d-sm-flex {
  justify-content: center !important;
}

.hero-content > div.d-sm-flex {
  justify-content: center !important;
}

.hero .container {
  position: relative;
  z-index: 5;
}

.hero h1 {
  font-size: 3.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  max-width: 620px;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.hero p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 540px;
  margin-bottom: 2rem;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.search-panel {
  background-color: var(--card-bg);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  padding: 1.5rem;
  transition: background-color 0.3s ease;
}

.search-panel .form-control,
.search-panel .form-select {
  border-radius: 14px;
  border: 1px solid var(--border-color);
  padding: 0.9rem 1rem;
  background-color: var(--card-bg);
  color: var(--text-primary);
}

.search-panel .btn-brand {
  width: 100%;
  font-size: 1.05rem;
}

.property-card {
  border: none;
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  background-color: var(--card-bg);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.property-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.property-card img {
  height: 240px;
  object-fit: cover;
}

.property-content {
  padding: 1.75rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.property-content h3 {
  font-size: 1.4rem;
  margin-bottom: 0.75rem;
}

.property-content .d-flex.justify-content-between {
  gap: 0.5rem;
}

.property-content .d-flex.justify-content-between .btn {
  padding: 0.5rem 0.75rem;
  font-size: 0.8rem;
  flex: 1;
  min-width: 0;
  text-align: center;
  white-space: normal;
  line-height: 1.3;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.property-meta {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  align-items: center;
  margin-bottom: 1rem;
}

.price-tag {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--brand-primary);
}

.price-tag.price-inline {
  font-size: 0.95rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
  grid-column: -1;
  justify-self: end;
}

.feature-badge {
  position: absolute;
  top: 18px;
  left: 18px;
  background: rgba(42, 125, 225, 0.9);
  color: #ffffff;
  padding: 0.45rem 1.1rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.amenities {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
  color: var(--text-muted);
  align-items: start;
}

.amenities li {
  display: flex;
  align-items: center;
  line-height: 1.6;
  font-size: 0.9rem;
  min-height: 1.6em;
}

.amenities li i {
  margin-right: 0.625rem;
  color: var(--brand-secondary);
  width: 1.2em;
  text-align: center;
  flex-shrink: 0;
  font-size: 1rem;
}

.stat-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow-sm);
  text-align: center;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: background-color 0.3s ease;
}

.stat-card h3 {
  font-size: 3rem;
  font-weight: 700;
  color: var(--brand-primary);
}

.stat-card p {
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.testimonial-card {
  background-color: var(--card-bg);
  transition: background-color 0.3s ease;
  border-radius: var(--card-radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.testimonial-card .client {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.testimonial-card img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
}

.team-card {
  text-align: center;
  background: var(--card-bg);
  border-radius: var(--card-radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: background-color 0.3s ease;
  transition: var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.team-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.team-card img {
  height: 280px;
  width: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
}

.team-card > .p-3 {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
}

.team-card h4 {
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
}

.team-card p {
  margin-bottom: 1rem;
  flex: 1;
}

.team-card .social-links {
  margin-top: auto;
  display: flex;
  justify-content: center;
  gap: 0.75rem;
}

.team-card .social-links a {
  color: var(--brand-primary);
  font-size: 1.1rem;
  transition: var(--transition-base);
}

.team-card .social-links a:hover {
  color: var(--brand-secondary);
  transform: translateY(-2px);
}

.timeline {
  border-left: 3px solid rgba(42, 125, 225, 0.25);
  padding-left: 1.5rem;
  position: relative;
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -2.15rem;
  top: 3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--brand-primary);
}

.timeline-item h4 {
  font-size: 1.25rem;
  font-weight: 600;
}

.cta-banner {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
  color: #ffffff;
  border-radius: var(--card-radius);
  padding: 3rem;
  box-shadow: var(--shadow-lg);
}

.cta-banner h2 {
  font-size: 2.1rem;
  margin-bottom: 1rem;
}

.cta-banner p {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 1.5rem;
}

.page-hero {
  padding: 6rem 0 4rem;
  background: linear-gradient(135deg, rgba(42, 125, 225, 0.15), rgba(27, 216, 166, 0.15));
  text-align: center;
}

.page-hero h1 {
  font-size: 3rem;
  font-weight: 700;
  color: var(--text-primary);
}

.page-hero h3 {
  color: var(--text-secondary);
}

.breadcrumb {
  justify-content: center;
  gap: 0.5rem;
  font-weight: 500;
}

.breadcrumb a {
  color: var(--brand-primary);
}

.breadcrumb-item {
  color: inherit;
}

.breadcrumb-item.active {
  color: inherit;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.featured-card {
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background-color: var(--card-bg);
  transition: var(--transition-base);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.featured-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.featured-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
}

.featured-card .content {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.featured-card .content h3 {
  margin-bottom: 0.5rem;
  font-size: 1.4rem;
}

.featured-card .content p {
  flex: 1;
  margin-bottom: 0;
  color: var(--text-muted);
}

.featured-card .content .btn-sm {
  padding: 0.5rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  width: 120px;
  text-align: center;
  white-space: normal;
  line-height: 1.3;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.map-container {
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.map-container-full {
  width: 100%;
  height: 500px;
  overflow: hidden;
}

.map-container-full iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.contact-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  padding: 2.25rem;
  box-shadow: var(--shadow-sm);
  transition: background-color 0.3s ease;
}

.contact-card .info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-card .info-item i {
  font-size: 1.4rem;
  color: var(--brand-secondary);
}

.form-control,
.form-select,
textarea {
  border-radius: 14px;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(23, 52, 95, 0.12);
  transition: var(--transition-base);
  font-size: 0.95rem;
}

.form-select {
  min-width: 180px;
}

.form-control:focus,
.form-select:focus,
textarea:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 0.15rem rgba(42, 125, 225, 0.15);
}

.tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: nowrap;
  overflow-x: auto;
}

.tag {
  background-color: rgba(42, 125, 225, 0.08);
  color: var(--brand-primary);
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  font-size: 0.75rem;
  white-space: nowrap;
  flex-shrink: 0;
}

.rating {
  color: #f5a623;
}

.footer {
  background-color: #0f1724;
  color: rgba(255, 255, 255, 0.85);
  padding: 4rem 0 2.5rem;
}

.footer img {
  height: 42px;
  display: block;
}

.footer svg {
  height: 42px;
  width: auto;
  display: block;
}

.footer h5 {
  font-size: 1.15rem;
  margin-bottom: 1.5rem;
}

.footer p,
.footer a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.95rem;
}

.footer a:hover {
  color: var(--brand-secondary);
}

.footer .social-links {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: flex-start;
}

.footer .social-links a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-base);
  text-decoration: none;
  background-color: transparent;
  flex-shrink: 0;
}

.footer .social-links a svg {
  width: 24px;
  height: 24px;
  display: block;
  transition: 0.3s ease;
}

.footer .social-links a:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-sm);
}

.footer .social-links a:hover svg {
  transform: translateY(-3px);
  opacity: 0.8;
}

.footer .contact-info a {
  display: block;
  margin-bottom: 0.75rem;
}

.footer .contact-info i {
  margin-right: 0.5rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 3rem;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.95rem;
}

.footer-bottom p {
  color: var(--footer-text) !important;
}

.footer-bottom #currentYear {
  color: var(--footer-text) !important;
  opacity: 1;
}

.login-card,
.register-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  padding: 2.5rem;
  box-shadow: var(--shadow-lg);
  max-width: 460px;
  margin: 0 auto;
  transition: background-color 0.3s ease;
}

.auth-switch {
  margin-top: 1.5rem;
  text-align: center;
  color: var(--text-muted);
}

.service-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(42, 125, 225, 0.08);
  justify-content: center;
  align-items: center;
  overflow-wrap: break-word;
  word-wrap: break-word;
  box-sizing: border-box;
}

.service-items {
  display: flex;
  gap: 2rem;
  width: 100%;
  justify-content: space-between;
}

.service-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
  gap: 0.75rem;
}

.service-item i {
  font-size: 2rem;
  color: var(--brand-secondary);
  margin-bottom: 0.5rem;
}

.service-item span {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.5;
  font-weight: 500;
  text-align: center;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(42, 125, 225, 0.2);
}

.service-card .badge-soft {
  display: inline-block;
  margin-bottom: 1rem;
  align-self: flex-start;
}

.service-card h4 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  line-height: 1.4;
  color: var(--text-primary);
}

.service-card p {
  flex: 1;
  margin-bottom: 1.5rem;
  line-height: 1.7;
  font-size: 0.95rem;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.service-card a {
  overflow-wrap: break-word;
  word-wrap: break-word;
  word-break: break-all;
  max-width: 100%;
  display: inline-block;
}

/* Global Offices section - ensure emails stay within cards */
.service-card[style*="align-items: flex-start"] {
  align-items: flex-start !important;
  text-align: left !important;
}

.service-card[style*="align-items: flex-start"] a {
  word-break: break-all;
  overflow-wrap: anywhere;
  max-width: 100%;
}

.service-card[style*="height: auto"] {
  height: auto;
}

.service-card[style*="height: auto"] p {
  flex: none;
}

.service-card.compact-card {
  padding: 0.625rem 0.875rem;
  margin-bottom: 0;
}

.service-card.compact-card h4 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
  line-height: 1.3;
}

.service-card.compact-card p.small {
  font-size: 0.875rem;
  line-height: 1.4;
  margin-bottom: 0;
}

.section-heading.text-lg-start.mb-3 {
  margin-bottom: 0.75rem !important;
}

.section-heading.text-lg-start h3 {
  margin-top: 0.25rem !important;
}

.service-card .btn {
  margin-top: auto;
}

.badge-soft {
  background-color: rgba(27, 216, 166, 0.12);
  color: var(--brand-secondary);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.step-number {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(42, 125, 225, 0.15);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: var(--brand-primary);
}

.profile-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  box-shadow: var(--shadow-lg);
  overflow: visible;
  transition: background-color 0.3s ease;
}

.profile-header {
  position: relative;
  overflow: hidden;
  border-radius: var(--card-radius) var(--card-radius) 0 0;
}

.profile-header img.cover {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.profile-header .avatar {
  position: absolute;
  bottom: -48px;
  left: 50%;
  transform: translateX(-50%);
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 4px solid var(--card-bg);
  object-fit: cover;
  z-index: 10;
  background-color: var(--card-bg);
  display: block;
}

.profile-body {
  padding: 4rem 2.5rem 2.5rem;
  text-align: center;
}

.profile-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 1.5rem;
}

.profile-stats div {
  color: var(--text-muted);
}

.profile-stats strong {
  display: block;
  font-size: 1.4rem;
  color: var(--brand-primary);
}

.property-gallery {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1rem;
}

.property-gallery img {
  border-radius: 16px;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.property-gallery .thumbs {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1rem;
}

.property-gallery .thumbs img {
  height: 140px;
}

.property-summary {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  box-shadow: var(--shadow-sm);
  padding: 2rem;
  transition: background-color 0.3s ease;
}

.property-summary ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.property-summary li {
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
}

.property-map iframe {
  width: 100%;
  height: 350px;
  border: 0;
}

.badge-premium {
  background: rgba(234, 179, 62, 0.18);
  color: #d97706;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  font-weight: 600;
}

.tag-outline {
  border: 1px solid rgba(42, 125, 225, 0.35);
  color: var(--brand-primary);
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.85rem;
  white-space: nowrap;
  min-width: 100px;
  width: 100px;
  text-align: center;
  display: inline-block;
}

.floating-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background-color: var(--card-bg);
  color: var(--text-primary);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.gallery-slider img {
  border-radius: var(--card-radius);
}

.accordion-button:not(.collapsed) {
  color: var(--brand-primary);
  background-color: rgba(42, 125, 225, 0.08);
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.1);
}

.accordion-button:focus {
  box-shadow: 0 0 0 0.15rem rgba(42, 125, 225, 0.2);
}

.badge-status {
  padding: 0.35rem 1.1rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.85rem;
}

.badge-available {
  background-color: rgba(16, 185, 129, 0.1);
  color: #047857;
}

.badge-sold {
  background-color: rgba(239, 68, 68, 0.1);
  color: #b91c1c;
}

.filter-pill {
  padding: 0.4rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background-color: var(--card-bg);
  color: var(--text-primary);
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition-base);
  font-size: 0.95rem;
}

.filter-pill:hover {
  background-color: rgba(42, 125, 225, 0.1);
  transform: translateY(-1px);
}

.filter-pill.active {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
  color: #ffffff;
  border-color: transparent;
}

.filter-pill.active:hover {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.listing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 1.75rem;
  width: 100%;
  align-items: start;
}

.listing-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  align-items: stretch;
}

.listing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.listing-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  display: block;
}

.listing-card .content {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 0;
  width: 100%;
  box-sizing: border-box;
}

.listing-card .content h3 {
  font-size: 1.4rem;
  margin-bottom: 0.75rem;
  line-height: 1.3;
  word-wrap: break-word;
}

.listing-card .content p {
  margin-bottom: 1rem;
  line-height: 1.6;
  flex-shrink: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.listing-card .meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, max-content));
  gap: 0.75rem 1rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0 0 1rem 0;
  flex-shrink: 0;
  align-items: center;
  width: 100%;
  line-height: 1.5;
}

.listing-card .meta span {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
  min-height: 1.5em;
  justify-content: flex-start;
}

.listing-card .meta span i {
  margin-right: 0.4rem;
  color: var(--brand-secondary);
  flex-shrink: 0;
  width: 1em;
  text-align: center;
}

.listing-card .content > div:last-child {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
  margin-bottom: 0;
  flex-shrink: 0;
}

.listing-card .content > div:last-child .d-flex {
  flex-wrap: nowrap;
  gap: 0.5rem;
}

.listing-card .content > div:last-child .btn {
  white-space: nowrap;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  flex: 1;
  min-width: 0;
}

.add-property-steps {
  display: grid;
  gap: 1.5rem;
}

.add-property-card {
  background-color: var(--card-bg);
  border-radius: var(--card-radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: background-color 0.3s ease;
}

.success-message,
.error-message {
  display: none;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 12px;
  font-weight: 500;
}

.success-message {
  background-color: rgba(16, 185, 129, 0.12);
  color: #047857;
}

.error-message {
  background-color: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
}

@media (max-width: 991px) {
  .navbar-nav .nav-link {
    padding: 0.65rem 0.5rem;
  }

  .hero {
    padding: 6rem 0 4rem;
  }

  .hero h1 {
    font-size: 2.6rem;
  }

  .hero-content .d-sm-flex,
  .hero-content > div.d-sm-flex {
    justify-content: center !important;
  }

  .search-panel {
    margin-top: 2rem;
  }
}

@media (max-width: 768px) {
  section {
    padding: 3rem 0;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .property-gallery {
    grid-template-columns: 1fr;
  }

  .property-gallery .thumbs {
    grid-template-columns: repeat(2, 1fr);
  }

  .profile-stats {
    flex-direction: column;
    gap: 1.5rem;
  }

  .listing-grid {
    grid-template-columns: 1fr;
    width: 100%;
    gap: 1.5rem;
  }

  .listing-card {
    width: 100%;
    max-width: 100%;
  }
  
  .listing-card .content {
    width: 100%;
    padding: 1.5rem;
  }

  .listing-card .meta {
    width: 100%;
    margin-bottom: 1rem;
  }
  
  .listing-card .content > div:last-child {
    width: 100%;
  }
  
  .listing-card .content > div:last-child .d-flex {
    flex-wrap: nowrap;
    gap: 0.4rem;
    width: 100%;
  }
  
  .listing-card .content > div:last-child .btn {
    flex: 1;
    padding: 0.45rem 0.75rem;
    font-size: 0.8rem;
  }
}

/* Theme Toggle Button */
.theme-toggle {
  background: transparent;
  border: 2px solid var(--text-primary);
  color: var(--text-primary);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-base);
  margin-left: 1rem;
  font-size: 1.1rem;
  z-index: 1050;
}

.theme-toggle:hover {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #ffffff;
  transform: scale(1.1);
}

.theme-toggle i {
  transition: transform 0.3s ease;
}

/* Update text colors for visibility */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  transition: color 0.3s ease;
}

p, span, li, td, th {
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.text-muted {
  color: var(--text-secondary) !important;
}

/* Update form controls */
.form-control, .form-select {
  background-color: var(--card-bg);
  color: var(--text-primary);
  border-color: var(--border-color);
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.form-control:focus, .form-select:focus {
  background-color: var(--card-bg);
  color: var(--text-primary);
  border-color: var(--brand-primary);
}

/* Update navbar text */
.navbar-nav .nav-link {
  color: var(--text-primary);
  transition: color 0.3s ease;
}

/* Update footer */
.footer {
  background-color: var(--footer-bg);
  color: var(--footer-text);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.footer h5 {
  color: #ffffff;
}

.footer p, .footer a {
  color: var(--footer-text);
}

/* Update sections */
section {
  background-color: var(--bg-primary);
  transition: background-color 0.3s ease;
}

.bg-white {
  background-color: var(--card-bg) !important;
}

.bg-light {
  background-color: var(--bg-secondary) !important;
}

/* Update dropdown menu */
.dropdown-menu {
  background-color: var(--card-bg);
  border-color: var(--border-color);
  transition: background-color 0.3s ease;
}

.dropdown-item {
  color: var(--text-primary);
  transition: color 0.3s ease, background-color 0.3s ease;
}

.dropdown-item:hover, .dropdown-item:focus {
  background-color: var(--bg-secondary);
  color: var(--text-primary);
}

/* Update property content text */
.property-content h3, .property-content h4 {
  color: var(--text-primary);
}

.property-content p {
  color: var(--text-secondary);
}

/* Update listing card text */
.listing-card h3, .listing-card h4 {
  color: var(--text-primary);
}

.listing-card p {
  color: var(--text-secondary);
}

/* Comprehensive Dark Mode Overrides */
html[data-theme="dark"] .hero {
  background: linear-gradient(135deg, rgba(42, 125, 225, 0.15), rgba(27, 216, 166, 0.15));
}

html[data-theme="dark"] .hero::after {
  opacity: 0.15;
}

html[data-theme="dark"] .page-hero {
  background: linear-gradient(135deg, rgba(42, 125, 225, 0.2), rgba(27, 216, 166, 0.2));
}

html[data-theme="dark"] .topbar {
  background-color: var(--brand-dark);
}

html[data-theme="dark"] .breadcrumb {
  color: #ffffff;
}

html[data-theme="dark"] .breadcrumb-item {
  color: #ffffff;
}

html[data-theme="dark"] .breadcrumb-item.active {
  color: #ffffff;
}

html[data-theme="dark"] .breadcrumb-item + .breadcrumb-item::before {
  color: #ffffff;
  opacity: 0.8;
}

html[data-theme="dark"] .breadcrumb a {
  color: var(--brand-primary);
}

html[data-theme="dark"] .property-content h3,
html[data-theme="dark"] .property-content h4,
html[data-theme="dark"] .property-content h5 {
  color: var(--text-primary);
}

html[data-theme="dark"] .property-meta {
  color: var(--text-secondary);
}

html[data-theme="dark"] .price-tag {
  color: var(--brand-primary);
}

html[data-theme="dark"] .amenities li {
  color: var(--text-secondary);
}

html[data-theme="dark"] .stat-card h3 {
  color: var(--brand-primary);
}

html[data-theme="dark"] .stat-card p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .testimonial-card {
  color: var(--text-primary);
}

html[data-theme="dark"] .team-card h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .team-card p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .featured-card .content h3 {
  color: var(--text-primary);
}

html[data-theme="dark"] .featured-card .content p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .contact-card h2,
html[data-theme="dark"] .contact-card h4,
html[data-theme="dark"] .contact-card h5 {
  color: var(--text-primary);
}

html[data-theme="dark"] .contact-card p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .service-card h3,
html[data-theme="dark"] .service-card h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .service-card p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .profile-body h3,
html[data-theme="dark"] .profile-body h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .profile-stats div {
  color: var(--text-secondary);
}

html[data-theme="dark"] .profile-stats strong {
  color: var(--brand-primary);
}

html[data-theme="dark"] .property-summary h3,
html[data-theme="dark"] .property-summary h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .property-summary li {
  color: var(--text-secondary);
}

html[data-theme="dark"] .filter-pill:hover {
  background-color: var(--bg-secondary);
  border-color: var(--brand-primary);
  color: var(--text-primary);
}

html[data-theme="dark"] .property-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .team-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .featured-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .listing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

html[data-theme="dark"] .listing-card .content h3,
html[data-theme="dark"] .listing-card .content h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .listing-card .content p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .listing-card .meta {
  color: var(--text-secondary);
}

html[data-theme="dark"] .add-property-card h3,
html[data-theme="dark"] .add-property-card h4 {
  color: var(--text-primary);
}

html[data-theme="dark"] .add-property-card p,
html[data-theme="dark"] .add-property-card label {
  color: var(--text-secondary);
}

html[data-theme="dark"] .login-card h2,
html[data-theme="dark"] .register-card h2 {
  color: var(--text-primary);
}

html[data-theme="dark"] .login-card label,
html[data-theme="dark"] .register-card label {
  color: var(--text-primary);
}

html[data-theme="dark"] .auth-switch {
  color: var(--text-secondary);
}

html[data-theme="dark"] .auth-switch a {
  color: var(--brand-primary);
}

html[data-theme="dark"] .section-heading h2 {
  color: var(--text-primary);
}

html[data-theme="dark"] .section-heading h3 {
  color: var(--text-secondary);
}

html[data-theme="dark"] .section-heading p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(241, 245, 249, 0.8)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

html[data-theme="dark"] .accordion-button {
  background-color: var(--card-bg);
  color: var(--text-primary);
  border-color: var(--border-color);
}

html[data-theme="dark"] .accordion-button:not(.collapsed) {
  background-color: var(--bg-secondary);
  color: var(--brand-primary);
}

html[data-theme="dark"] .accordion-body {
  background-color: var(--card-bg);
  color: var(--text-primary);
}

html[data-theme="dark"] .accordion-item {
  background-color: var(--card-bg);
  border-color: var(--border-color);
}

html[data-theme="dark"] .table {
  color: var(--text-primary);
}

html[data-theme="dark"] .table thead th {
  color: var(--text-primary);
  border-color: var(--border-color);
}

html[data-theme="dark"] .table tbody td {
  color: var(--text-primary);
  border-color: var(--border-color);
}

html[data-theme="dark"] .modal-content {
  background-color: var(--card-bg);
  color: var(--text-primary);
}

html[data-theme="dark"] .modal-header {
  border-color: var(--border-color);
}

html[data-theme="dark"] .modal-footer {
  border-color: var(--border-color);
}

html[data-theme="dark"] .alert {
  background-color: var(--card-bg);
  border-color: var(--border-color);
  color: var(--text-primary);
}

html[data-theme="dark"] .timeline {
  border-left-color: var(--border-color);
}

html[data-theme="dark"] .timeline-item::before {
  background: var(--brand-primary);
}

html[data-theme="dark"] .map-container {
  background-color: var(--card-bg);
}

html[data-theme="dark"] .gallery-slider {
  background-color: var(--card-bg);
}

html[data-theme="dark"] ul.list-unstyled li a {
  color: var(--text-primary);
}

html[data-theme="dark"] ul.list-unstyled li a:hover {
  color: var(--brand-primary);
}

html[data-theme="dark"] .hero h1 {
  color: var(--text-primary);
}

html[data-theme="dark"] .hero p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .page-hero h1 {
  color: var(--text-primary);
}

html[data-theme="dark"] .page-hero h3 {
  color: var(--text-secondary);
}

html[data-theme="dark"] .page-hero p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .cta-banner h2 {
  color: #ffffff;
}

html[data-theme="dark"] .cta-banner p {
  color: rgba(255, 255, 255, 0.9);
}

html[data-theme="dark"] .price-tag {
  color: var(--brand-primary);
}

html[data-theme="dark"] .property-meta {
  color: var(--text-secondary);
}

html[data-theme="dark"] .tag-outline {
  border-color: var(--border-color);
  color: var(--text-primary);
  background-color: var(--card-bg);
}

html[data-theme="dark"] .tag-outline:hover {
  border-color: var(--brand-primary);
  background-color: var(--bg-secondary);
}

html[data-theme="dark"] .badge-premium {
  background: rgba(234, 179, 62, 0.25);
  color: #fbbf24;
}

html[data-theme="dark"] .badge-available {
  background-color: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

html[data-theme="dark"] .badge-sold {
  background-color: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

html[data-theme="dark"] .step-number {
  background: rgba(42, 125, 225, 0.2);
  color: var(--brand-primary);
}

html[data-theme="dark"] .step p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .step h4 {
  color: var(--text-primary);
}

@media (max-width: 576px) {
  .topbar {
    padding: 0.75rem 0;
  }

  .topbar .container {
    flex-direction: column !important;
    gap: 0.5rem;
    align-items: flex-start;
    justify-content: flex-start;
    width: 100%;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .topbar .social-links {
    order: 0;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    margin: 0;
    padding: 0;
    display: flex !important;
    flex-wrap: nowrap;
    gap: 0.75rem;
    margin-left: 0;
  }

  .topbar .social-links a {
    width: 36px;
    height: 36px;
    margin: 0 !important;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .topbar .contact-info {
    order: 1;
    width: 100%;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0.5rem !important;
    margin: 0;
    padding: 0;
    margin-left: 0;
  }

  .topbar .contact-info a {
    display: block !important;
    margin: 0 !important;
    padding: 0;
    text-align: left;
    direction: ltr;
    width: auto;
    white-space: nowrap;
    line-height: 1.5;
  }
}

  .hero {
    text-align: center;
  }

  .search-panel .row > * {
    margin-bottom: 1rem;
  }

  .search-panel .btn-brand {
    margin-top: 0.5rem;
  }
  
  .theme-toggle {
    width: 36px;
    height: 36px;
    font-size: 1rem;
    margin-left: 0.5rem;
  }
}

.pagination {
  justify-content: center;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.pagination .page-item {
  margin: 0.25rem;
}

