/* ==========================================================================
   FlatXHub Master Platform Stylesheet - Reaching the Right Tenants
   ========================================================================== */


:root {
  --bg-warm: #FFFBEB;
  --bg-white: #FFFFFF;
  --bg-page: #FDFBF7;
  --brand-yellow: #F5A623;
  --brand-dark: #1E293B;
  --green-primary: #F5A623; /* FlatXHub Primary Accent */
  --green-hover: #D97706;  /* FlatXHub Primary Hover */
  --green-light: #FEF3C7;  /* FlatXHub Soft Light Tint */
  --text-dark: #0F172A;
  --text-muted: #64748B;
  --border-light: #E2E8F0;
  --font-inter: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --font-jakarta: 'Plus Jakarta Sans', sans-serif;
  --shadow-card: 0 8px 24px rgba(0, 0, 0, 0.06);
  --shadow-drop: 0 12px 28px rgba(0, 0, 0, 0.08);
}

/* Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-jakarta);
  color: var(--text-dark);
  background-color: var(--bg-white);
  line-height: 1.5;
  overflow-x: hidden;
  min-height: 100vh;
}

button, input, select, textarea {
  font-family: inherit;
}

.container {
  width: calc(100% - 80px);
  max-width: 1450px;
  margin: auto;
}

/* ==========================================================================
   1. HEADER COMPONENT
   ========================================================================== */
.flatx-header {
  background: var(--bg-white);
  border-bottom: 1.5px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 0.5rem 1.5rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.header-container {
  max-width: 1480px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.brand-logo {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  line-height: 0;
}

.brand-logo-img {
  height: 46px;
  width: auto;
  object-fit: contain;
  display: block;
  transition: transform 0.2s ease;
}

.brand-logo-img:hover {
  transform: scale(1.02);
}

.pro-badge {
  background: #1E293B;
  color: #F5A623;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.25rem 0.65rem;
  border-radius: 10px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: nowrap;
}

.nav-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  color: #1E293B;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.86rem;
  padding: 0.4rem 0.55rem;
  border-radius: 10px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.nav-item:hover, .nav-item.active {
  color: #F5A623;
  background: #FFFBEB;
}

.nav-icon {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  /* Same rounded stroke style as every other icon on the site (profile menu, cards) - without it the
     heart's tip and inner curve render with sharp mitred corners. */
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.post-property-link {
  position: relative;
}

.free-pill {
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.15rem 0.45rem;
  border-radius: 10px;
  margin-right: 2px;
}

.header-right {
  display: flex;
  align-items: center;
}

.user-pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  height: 46px;
  padding: 0 22px;
  border-radius: 23px;
  background: #1E293B;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(30, 41, 59, 0.18);
  transition: all 0.15s ease;
}

.user-pill-btn:hover {
  background: #0f172a;
  transform: translateY(-1px);
}
  right: 10px;
  background: var(--green-primary);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

.header-right {
  display: flex;
  align-items: center;
}

.user-pill-btn {
  background: var(--green-primary);
  color: #111827; /* dark on amber: white was only 2:1 contrast */
  text-decoration: none;
  border: none;
  padding: 0.5rem 1.4rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 12px rgba(30, 86, 65, 0.25);
  transition: background 0.2s ease;
}

.user-pill-btn:hover {
  background: var(--green-hover);
  color: #111827;
}

.user-icon {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   2. LANDING PAGE (Hero, Recent Listings, How It Works, Collage, Reviews)
   ========================================================================== */
.hero-section {
  background: var(--bg-warm);
  padding: 4rem 2rem 0;
  position: relative;
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  padding-bottom: 3rem;
}

.hero-title {
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1.15;
  color: var(--text-dark);
  margin-bottom: 1rem;
}

.highlight-pill {
  display: inline-block;
  border: 2px dashed #000;
  padding: 0.2rem 1.2rem;
  border-radius: 40px;
  background: rgba(255, 255, 255, 0.4);
}

.hero-subtitle {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 2rem;
  font-weight: 500;
}

.search-box-wrap {
  max-width: 440px;
}

.search-input-group {
  background: var(--bg-white);
  border: 1px solid #CBD5E1;
  border-radius: 30px;
  padding: 0.4rem 0.5rem 0.4rem 1.2rem;
  display: flex;
  align-items: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.04);
}

.search-icon {
  font-size: 1rem;
  margin-right: 0.6rem;
}

.search-field {
  border: none;
  outline: none;
  flex: 1;
  font-size: 0.95rem;
  color: var(--text-dark);
  background: transparent;
}

.search-btn {
  background: var(--green-primary);
  color: #fff;
  border: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.search-btn:hover {
  background: var(--green-hover);
}

.hero-graphic {
  display: flex;
  justify-content: center;
}

.arch-image-frame {
  position: relative;
  width: 380px;
  height: 280px;
  border-radius: 190px 190px 20px 20px;
  overflow: visible;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 190px 190px 20px 20px;
}

.vibe-bubble {
  position: absolute;
  background: #fff;
  border: 1px solid #E2E8F0;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-dark);
  box-shadow: 0 4px 10px rgba(0,0,0,0.06);
}

.bubble-1 { top: 20px; left: 10px; }
.bubble-2 { top: 60px; right: 10px; }
.bubble-3 { top: 140px; left: -15px; }
.bubble-4 { bottom: 30px; right: 10px; }

.wave-divider {
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.wave-divider svg {
  width: 100%;
  height: 60px;
}

.recent-listings-section {
  background: #FFFFFF;
  padding: 3rem 2rem 5rem;
}

.section-container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2.5rem;
}

.section-heading {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-dark);
}

.btn-outline-pill {
  background: transparent;
  border: 1.5px solid #000;
  padding: 0.5rem 1.4rem;
  border-radius: 30px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-outline-pill:hover {
  background: #000;
  color: #fff;
}

.how-it-works-section {
  background: var(--bg-warm);
  padding: 4rem 2rem 6rem;
  position: relative;
  overflow: hidden;
}

/* Drifting color blobs behind the timeline — same bold/vibrant language as
   the hero on index.php, so this section doesn't feel like a flat, static
   afterthought below it. */
.how-it-works-section::before,
.how-it-works-section::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  opacity: 0.25;
  pointer-events: none;
  animation: worksBlobDrift 16s ease-in-out infinite alternate;
}
/* Radial gradients, not filter: blur() — same soft glow, far cheaper to
   animate. Boxes are larger than the old circles by the blur spread. */
.how-it-works-section::before {
  width: 560px; height: 560px; background: radial-gradient(closest-side, #c065d6 25%, rgba(192,101,214,0) 100%);
  top: -180px; right: -200px;
}
.how-it-works-section::after {
  width: 500px; height: 500px; background: radial-gradient(closest-side, #F5A623 25%, rgba(245,166,35,0) 100%);
  bottom: -200px; left: -180px; animation-duration: 20s; animation-delay: -6s;
}
@keyframes worksBlobDrift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(26px, -20px) scale(1.1); }
}

.text-center { text-align: center; }

.works-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 4rem;
  position: relative;
}

.works-pill {
  display: inline-block;
  background: linear-gradient(90deg, #F5A623, #ec4899);
  color: #fff;
  padding: 0.2rem 1.2rem;
  border-radius: 30px;
  transform: rotate(-3deg);
  box-shadow: 0 6px 16px rgba(236,72,153,0.3);
  animation: pillWiggle 4s ease-in-out infinite;
}
@keyframes pillWiggle {
  0%, 100% { transform: rotate(-3deg); }
  50% { transform: rotate(3deg); }
}

.timeline-container {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  z-index: 1;
}

.timeline-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 3px;
  background: linear-gradient(180deg, #F5A623, #ec4899, #8b5cf6);
  transform: translateX(-50%);
  transform-origin: top;
  scale: 1 0;
  transition: scale 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.timeline-line.line-in { scale: 1 1; }

.timeline-step {
  display: flex;
  align-items: center;
  margin-bottom: 4rem;
  width: 100%;
  opacity: 0;
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.timeline-step.step-in { opacity: 1; transform: translateX(0) !important; }

.step-left { flex-direction: row; transform: translateX(-50px); }
.step-right { flex-direction: row-reverse; transform: translateX(50px); }

.step-media {
  width: 45%;
  display: flex;
  justify-content: center;
}

.step-img {
  width: 220px;
  height: 150px;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: var(--shadow-card);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.step-media:hover .step-img {
  transform: scale(1.06) rotate(-1deg);
  box-shadow: 0 16px 32px rgba(139,92,246,0.25);
}

.step-dot {
  position: relative;
  width: 14px;
  height: 14px;
  background: linear-gradient(135deg, #F5A623, #ec4899);
  border-radius: 50%;
  z-index: 10;
  margin: 0 1rem;
  box-shadow: 0 0 0 4px #fff;
}
.step-dot::after {
  content: '';
  position: absolute; inset: -6px;
  border-radius: 50%;
  border: 2px solid #ec4899;
  opacity: 0;
  animation: dotPulse 2.4s ease-out infinite;
}
.timeline-step:nth-child(3) .step-dot::after { animation-delay: 0.4s; }
.timeline-step:nth-child(4) .step-dot::after { animation-delay: 0.8s; }
@keyframes dotPulse {
  0% { transform: scale(0.6); opacity: 0.6; }
  100% { transform: scale(1.8); opacity: 0; }
}

.step-card {
  width: 45%;
  background: #FFF9F0;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 1.5rem;
  text-align: left;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.step-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(139,92,246,0.18);
  border-color: transparent;
}

.step-card h3 {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 0.4rem;
  color: var(--text-dark);
}

.step-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.experience-section {
  background: #FFFFFF;
  padding: 5rem 2rem;
}

.experience-title {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 3rem;
}

.feature-collage-card {
  background: #FFF9F0;
  border-radius: 24px;
  padding: 3rem 2rem;
  max-width: 900px;
  margin: 0 auto 5rem;
  position: relative;
  border: 1px solid #E2E8F0;
}

.collage-badge {
  display: inline-block;
  background: var(--green-primary);
  color: #111827;
  padding: 0.5rem 1.2rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0.4rem;
}

.collage-images-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.col-img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 12px;
}

.testimonials-container {
  max-width: 1050px;
  margin: 0 auto;
}

.reviews-title {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 3rem;
}

.reviews-carousel-wrapper {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 15px;
}

.reviews-carousel {
  display: flex;
  gap: 1.8rem;
  align-items: stretch;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  padding: 20px 10px 30px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.reviews-carousel::-webkit-scrollbar {
  display: none;
}

.review-card {
  flex: 0 0 340px;
  max-width: 85vw;
  scroll-snap-align: center;
  background: #FFFFFF;
  border: 1.5px solid #E2E8F0;
  border-radius: 20px;
  padding: 2rem 1.8rem;
  text-align: left;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  user-select: none;
}

.review-card.active, .review-card:hover {
  border: 2px solid #111111;
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.carousel-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #111111;
  color: #111111;
  font-size: 24px;
  line-height: 1;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 2px 4px 0 #111111;
  transition: all 0.15s ease;
}

.carousel-nav-btn:hover {
  background: #1E5641;
  color: #ffffff;
  border-color: #1E5641;
  box-shadow: 2px 4px 0 #143D2E;
}

.carousel-nav-btn.prev-btn { left: -15px; }
.carousel-nav-btn.next-btn { right: -15px; }

@media (max-width: 768px) {
  .carousel-nav-btn.prev-btn { left: -5px; }
  .carousel-nav-btn.next-btn { right: -5px; }
  .review-card { flex: 0 0 290px; }
}

.review-user {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
}

.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #1E5641;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
}

.stars { color: #F59E0B; font-size: 0.9rem; margin-left: auto; }

.review-heading {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #111827;
}

.review-text {
  font-size: 0.88rem;
  color: #4b5563;
  line-height: 1.6;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #CBD5E1;
  cursor: pointer;
  transition: all 0.2s ease;
}

.dot.active {
  background: #111111;
  width: 26px;
  border-radius: 12px;
}
}

.dot.active {
  background: #000;
  width: 20px;
  border-radius: 10px;
}

/* ==========================================================================
   3. FLATS & FLATMATES SEARCH & CARDS (Flats Page)
   ========================================================================== */
.search-box {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 20px;
  padding: 22px 26px;
  margin-bottom: 28px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

/* ============================================
   MODERN SEARCH & FILTER SECTION
   ============================================ */

.search-top {
  display: flex;
  gap: 16px;
  align-items: center;
}

.search-input {
  flex: 1;
  height: 56px;
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  display: flex;
  align-items: center;
  padding: 0 20px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-input:focus-within {
  border-color: #F5A623;
  box-shadow: 0 0 0 3px rgba(245,166,35,0.12);
}

.search-input span {
  font-size: 20px;
  color: #94a3b8;
}

.search-input input {
  width: 100%;
  border: none;
  outline: none;
  margin-left: 12px;
  font-size: 15px;
  color: #0f172a;
  font-weight: 500;
  background: transparent;
}

.search-input input::placeholder {
  color: #94a3b8;
  font-weight: 400;
}

.search-suggestions-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(15,23,42,0.14);
  z-index: 40;
  max-height: 340px;
  overflow-y: auto;
  padding: 6px;
}

.search-suggestion-group-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  padding: 8px 10px 4px;
}

.search-suggestion-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.search-suggestion-item svg { color: #94a3b8; flex-shrink: 0; }

.search-suggestion-item:hover,
.search-suggestion-item.is-active {
  background: #f8fafc;
}

.search-suggestion-item.is-active svg { color: #F5A623; }

.search-suggestion-empty {
  padding: 14px 10px;
  font-size: 13px;
  color: #94a3b8;
  text-align: center;
}

.sort {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.sort span {
  font-weight: 600;
  font-size: 14px;
  color: #64748b;
  white-space: nowrap;
}

.sort select {
  height: 56px;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  padding: 0 40px 0 16px;
  background-color: #ffffff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s;
}

.sort select:focus { border-color: #F5A623; }

.filters {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  align-items: center;
  flex-wrap: wrap;
}

.filters select {
  height: 46px;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 0 36px 0 14px;
  background-color: #ffffff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 14px;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.filters select:focus {
  border-color: #F5A623;
  box-shadow: 0 0 0 3px rgba(245,166,35,0.1);
}

.filter-button {
  height: 46px;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 0 18px;
  background: #ffffff;
  color: #0f172a;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  outline: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  transition: all 0.2s ease;
}

.filter-button:hover {
  border-color: #F5A623;
  color: #F5A623;
}

.search-button {
  height: 46px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #F5A623 0%, #e8940f 100%);
  color: #ffffff;
  padding: 0 24px;
  font-size: 14px;
  font-weight: 700;
  outline: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 12px rgba(245,166,35,0.35);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.search-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(245,166,35,0.45);
}

.view-buttons {
  display: flex;
  gap: 4px;
  margin-left: auto;
  background: #f1f5f9;
  border-radius: 10px;
  padding: 4px;
}

.view-buttons button {
  height: 36px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #64748b;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.view-buttons button:hover {
  background: #ffffff;
  color: #0f172a;
}

.view-buttons button.active {
  background: #ffffff;
  color: #F5A623;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.advanced {
  margin-top: 16px;
  padding: 20px 22px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 16px;
  box-shadow: inset 0 1px 0 #ffffff, 0 2px 10px rgba(15, 23, 42, 0.04);
  animation: advancedIn 0.25s ease;
}

@keyframes advancedIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

.advanced-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px 18px;
}

.advanced-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
}

.advanced-field label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
}

.advanced-field select {
  height: 46px;
  width: 100%;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 0 38px 0 14px;
  background-color: #ffffff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 13px center;
  background-size: 14px 14px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.advanced-field select:hover {
  border-color: #cbd5e1;
}

.advanced-field select:focus {
  border-color: #F5A623;
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.15);
}

@media (max-width: 640px) {
  .advanced { padding: 16px; border-radius: 14px; }
  .advanced-grid { grid-template-columns: 1fr; gap: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .advanced { animation: none; }
}

.hidden {
  display: none !important;
}

.results {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 35px 0 25px;
}

.results p {
  color: #888;
  font-size: 1rem;
  font-weight: 500;
}

.btn-reset {
  background: #e2e8f0;
  border: none;
  padding: 0.6rem 1.4rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
}

.property-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 60px;
}

/* PAGE-BY-PAGE PAGINATION — replaces the old "load more as you scroll"
   behavior (js/app.js's fetchApiProperties), which kept the ENTIRE
   scrolled-through result set in memory and re-rendered the whole,
   ever-growing list on every single scroll tick — the real cause of
   Browse feeling slower the further down you scrolled. Real,
   server-side LIMIT/OFFSET pagination (/api/v2/listings already
   supported page & limit) now replaces the grid with just one page's
   worth of results at a time, same as flipping pages on any normal
   site. */
.property-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: -30px 0 60px;
  flex-wrap: wrap;
}
.page-btn {
  min-width: 40px;
  height: 40px;
  padding: 0 6px;
  border-radius: 50%;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.page-btn:hover:not(:disabled):not(.active) {
  border-color: #F5A623;
  color: #b45309;
}
.page-btn.active {
  background: #0f172a;
  border-color: #0f172a;
  color: #F5A623;
  cursor: default;
}
.page-btn:disabled {
  opacity: 0.4;
  cursor: default;
}
.page-btn.page-arrow {
  border-radius: 50%;
  background: #fff;
}
.page-ellipsis {
  color: #94a3b8;
  font-weight: 700;
  padding: 0 4px;
  user-select: none;
}
@media (max-width: 640px) {
  .property-pagination { gap: 5px; }
  .page-btn { min-width: 34px; height: 34px; font-size: 12.5px; }
}

.property-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid #eee;
  box-shadow: 10px 10px 0 #f1e7db;
  transition: transform .2s ease, box-shadow .2s ease;
}

.property-card:hover {
  transform: translateY(-5px);
  box-shadow: 12px 12px 0 #ebdccb;
}

.property-image {
  height: 270px;
  position: relative;
}

.property-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.heart {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,.65);
  color: white;
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}

.heart:hover {
  transform: scale(1.1);
}

.property-content {
  padding: 20px;
}

.property-title {
  font-size: 23px;
  font-weight: 700;
  margin-bottom: 20px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #111827;
}

.price {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.price div {
  padding-left: 12px;
  border-left: 1px solid #ddd;
}

.price div:first-child {
  border-left: none;
  padding-left: 0;
}

.price span {
  display: block;
  color: #888;
  margin-bottom: 7px;
  font-size: 14px;
}

.price strong {
  font-size: 20px;
  color: #111;
  font-weight: 800;
}

.tags {
  display: flex;
  gap: 7px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.tags span {
  background: #eef5f1;
  color: var(--green-primary);
  padding: 6px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

/* ==========================================================================
   4. SAVED LISTINGS PAGE (saved.html)
   ========================================================================== */
.saved-page {
  padding: 50px 0 70px;
  min-height: 70vh;
}

.page-title {
  font-size: 36px;
  font-weight: 500;
  line-height: 1.2;
  color: #050505;
  margin-bottom: 40px;
}

.empty-card {
  width: 100%;
  max-width: 560px;
  min-height: 472px;
  margin: 0 auto;
  background: #ffffff;
  border: 1px solid #d7dfe5;
  border-radius: 10px;
  box-shadow: 0 12px 18px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 50px 35px;
}

.heart-wrapper {
  width: 100px;
  height: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 25px;
}

.heart-icon-svg {
  width: 82px;
  height: 82px;
  fill: #f1dac2;
  stroke: #000000;
  stroke-width: 1.2;
  stroke-linejoin: round;
  filter: drop-shadow(4px 4px 0 #000000);
}

.empty-title {
  color: #123d63;
  font-size: 31px;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 12px;
}

.empty-description {
  color: #3f75ac;
  font-size: 17px;
  line-height: 1.5;
  max-width: 470px;
  margin-bottom: 29px;
}

.browse-button {
  height: 54px;
  min-width: 233px;
  padding: 0 28px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  border: none;
  border-radius: 15px;
  background: #286b53;
  color: #ffffff;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 4px 4px 0 #000000;
  transition: background-color 0.2s ease, transform 0.1s ease, box-shadow 0.1s ease;
}

.browse-button:hover {
  background: #205c46;
}

.browse-button:active {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #000000;
}

.btn-search-ico {
  width: 20px;
  height: 20px;
  position: relative;
  display: inline-block;
}

.btn-search-ico::before {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  top: 0;
  left: 0;
}

.btn-search-ico::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 2px;
  background: #ffffff;
  transform: rotate(45deg);
  left: 11px;
  top: 13px;
  border-radius: 2px;
}

/* ==========================================================================
   5. MESSAGES PAGE (messages.html)
   ========================================================================== */
.messages-page {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 20px 50px;
  min-height: 70vh;
}

.page-header {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 30px;
}

.header-icon {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-primary);
  border-radius: 10px;
  flex-shrink: 0;
}

.header-message-icon {
  width: 24px;
  height: 20px;
  border: 2px solid #ffffff;
  border-radius: 4px;
  position: relative;
}

.header-message-icon::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  border-left: 2px solid #ffffff;
  border-bottom: 2px solid #ffffff;
  background: var(--green-primary);
  left: 2px;
  bottom: -5px;
  transform: skewY(-35deg);
}

.tabs-container {
  width: 100%;
  height: 57px;
  background: #ffffff;
  border: 1px solid #d7dfe5;
  border-radius: 10px;
  padding: 5px;
  display: flex;
  align-items: center;
  margin-bottom: 30px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.tab {
  height: 45px;
  flex: 1;
  border: none;
  background: transparent;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: #40566b;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.tab:hover {
  background: #f1f5f3;
}

.tab.active {
  background: var(--green-primary);
  color: #ffffff;
}

.tab-icon {
  width: 19px;
  height: 17px;
  position: relative;
  display: inline-block;
}

.message-tab-icon {
  border: 2px solid currentColor;
  border-radius: 3px;
}

.message-tab-icon::after {
  content: "";
  position: absolute;
  width: 6px;
  height: 6px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  left: 1px;
  bottom: -5px;
  background: transparent;
  transform: skewY(-35deg);
}

.activity-tab-icon {
  height: 20px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    transparent 15%,
    currentColor 15%,
    currentColor 25%,
    transparent 25%,
    transparent 42%,
    currentColor 42%,
    currentColor 52%,
    transparent 52%,
    transparent 67%,
    currentColor 67%,
    currentColor 77%,
    transparent 77%
  );
  clip-path: polygon(
    0 50%,
    15% 50%,
    25% 10%,
    42% 85%,
    55% 35%,
    67% 65%,
    80% 15%,
    100% 15%,
    100% 50%,
    80% 50%,
    67% 100%,
    55% 55%,
    42% 100%,
    25% 35%,
    18% 65%,
    0 65%
  );
}

.empty-message-card,
.activities-card {
  width: 100%;
  min-height: 227px;
  background: #ffffff;
  border: 1px solid #d7dfe5;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 35px 20px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.empty-icon {
  width: 51px;
  height: 42px;
  border: 5px solid #9da6b5;
  border-radius: 7px;
  position: relative;
  margin-bottom: 29px;
}

.empty-icon::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border-left: 5px solid #9da6b5;
  border-bottom: 5px solid #9da6b5;
  left: -5px;
  bottom: -12px;
  transform: skewY(-40deg);
  background: #ffffff;
}

.empty-title,
.activity-title {
  font-size: 20px;
  font-weight: 500;
  color: #294b6b;
  margin-bottom: 14px;
}

.empty-description,
.activity-description {
  font-size: 17px;
  font-weight: 400;
  color: #5c7590;
  line-height: 1.5;
}

.note {
  text-align: center;
  color: #5c7590;
  font-size: 15px;
  line-height: 1.5;
  margin-top: 15px;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.activity-large-icon {
  width: 48px;
  height: 48px;
  color: #9da6b5;
  margin-bottom: 20px;
  position: relative;
}

.activity-large-icon::before {
  content: "⌁";
  position: absolute;
  left: 0;
  top: -13px;
  font-size: 65px;
  line-height: 1;
  font-weight: 400;
}

/* ==========================================================================
   6. REFER PAGE (refer.html)
   ========================================================================== */
.refer-container {
  width: 100%;
  max-width: 1190px;
  margin: 0 auto;
  padding: 40px 20px 60px;
  min-height: 70vh;
}

.refer-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  font-size: 30px;
  font-weight: 500;
  color: #243f59;
  line-height: 1.2;
}

.gift-icon {
  width: 28px;
  height: 28px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.gift-icon svg {
  width: 28px;
  height: 28px;
  stroke: #243f59;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.description {
  margin: 0 0 31px;
  max-width: 900px;
  font-size: 20px;
  line-height: 1.5;
  color: #243f59;
  font-weight: 400;
}

.referral-card {
  width: calc(100% - 159px);
  min-height: 138px;
  border: 1px solid #d8e0e6;
  border-radius: 16px;
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.06);
  padding: 27px 25px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 25px;
  background: #ffffff;
}

.referral-info {
  display: flex;
  flex-direction: column;
}

.label {
  font-size: 13px;
  color: #68798b;
  margin-bottom: 12px;
  letter-spacing: 0.2px;
  text-transform: uppercase;
}

.referral-code {
  margin: 0 0 10px;
  font-size: 23px;
  line-height: 1;
  font-weight: 700;
  color: #071a2b;
  letter-spacing: 0.5px;
}

.helper-text {
  margin: 0;
  font-size: 15px;
  color: #63758a;
  line-height: 1.4;
}

.copy-button {
  border: none;
  outline: none;
  min-width: 128px;
  height: 50px;
  padding: 0 20px;
  border-radius: 10px;
  background: var(--green-primary);
  color: white;
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
}

.copy-button:hover {
  background: var(--green-hover);
}

.copy-button:active {
  transform: scale(0.98);
}

.whatsapp-button {
  height: 55px;
  padding: 0 27px;
  border: none;
  border-radius: 30px;
  background: var(--green-primary);
  color: white;
  font-size: 18px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16);
  transition: background 0.2s ease, transform 0.1s ease;
}

.whatsapp-button:hover {
  background: var(--green-hover);
}

.whatsapp-button:active {
  transform: scale(0.98);
}

.whatsapp-icon {
  width: 22px;
  height: 22px;
  display: inline-flex;
}

.whatsapp-icon svg {
  width: 22px;
  height: 22px;
  stroke: #25D366;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.toast-popup {
  position: fixed;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%) translateY(20px);
  background: #243f59;
  color: #fff;
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s ease;
  z-index: 3000;
}

.toast-popup.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ==========================================================================
   7. LOGIN PAGE (login.html)
   ========================================================================== */
.login-page {
  width: 100%;
  min-height: 75vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 50px 20px;
}

.login-card {
  width: 100%;
  max-width: 546px;
  background: #ffffff;
  border-radius: 28px;
  padding: 32px 29px 29px;
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.12);
  border: 1px solid #e2e8f0;
}

.login-header {
  text-align: center;
  margin-bottom: 41px;
}

.login-header h1 {
  color: #0b2947;
  font-size: 30px;
  line-height: 1.2;
  font-weight: 700;
  margin-bottom: 14px;
}

.subtitle {
  color: #516579;
  font-size: 17px;
  line-height: 1.5;
  margin-bottom: 12px;
}

.secure-text {
  color: #516579;
  font-size: 15px;
  line-height: 1.5;
}

.form-group {
  width: 100%;
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  color: #0c2947;
  font-size: 17px;
  line-height: 1.4;
  margin-bottom: 11px;
}

.phone-input {
  width: 100%;
  height: 49px;
  display: flex;
  background: #ffffff;
  border: 1px solid #d3d9df;
  border-radius: 14px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.phone-input:focus-within {
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(40, 107, 83, 0.10);
}

.country-code {
  width: 68px;
  min-width: 68px;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #40566b;
  font-size: 16px;
  border-right: 1px solid #d3d9df;
  background: #ffffff;
}

.phone-input input {
  flex: 1;
  width: 100%;
  height: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: #243b53;
  font-size: 16px;
  padding: 0 19px;
}

.phone-input input::placeholder {
  color: #a3abb4;
  opacity: 1;
}

.error-message {
  display: block;
  min-height: 18px;
  margin-top: 5px;
  color: #d14343;
  font-size: 13px;
  line-height: 1.4;
}

.otp-button {
  width: 100%;
  height: 59px;
  border: none;
  border-radius: 14px;
  background: var(--green-primary);
  color: #ffffff;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease, opacity 0.2s ease;
}

.otp-button:hover {
  background: var(--green-hover);
}

.otp-button:active {
  transform: scale(0.99);
}

.otp-button:disabled {
  background: #8aa99c;
  cursor: not-allowed;
  opacity: 0.9;
}

.signup-text {
  text-align: center;
  margin-top: 30px;
  color: #516579;
  font-size: 16px;
  line-height: 1.5;
}

.signup-text a {
  color: #0759d8;
  text-decoration: none;
  font-weight: 500;
  margin-left: 3px;
}

.signup-text a:hover {
  text-decoration: underline;
}

.success-message {
  width: 100%;
  margin-top: 15px;
  padding: 12px;
  border-radius: 10px;
  background: #e9f6ef;
  color: #246b4a;
  text-align: center;
  font-size: 14px;
  line-height: 1.4;
}

/* ==========================================================================
   8. RENTX POST PROPERTY PAGE (post-property.html)
   ========================================================================== */
.rentx-property-page {
  background: linear-gradient(
    to bottom,
    #f8ede1 0px,
    #f8ede1 255px,
    #ffffff 255px,
    #ffffff 100%
  );
  padding: 28px 0 80px;
  color: #182033;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  min-height: 80vh;
}

.rentx-property-page * {
  box-sizing: border-box;
}

.rentx-property-page button,
.rentx-property-page input,
.rentx-property-page select {
  font-family: inherit;
}

.rentx-progress-card {
  width: calc(100% - 40px);
  max-width: 880px;
  margin: 0 auto;
  padding: 20px 26px 30px;
  background: #ffffff;
  border-radius: 22px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.rentx-progress-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.rentx-progress-title h1 {
  margin: 0 0 14px;
  font-size: 25px;
  font-weight: 600;
  letter-spacing: -0.5px;
}

.rentx-progress-title p {
  margin: 0;
  font-size: 14px;
  color: #5e6878;
}

.rentx-progress-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.rentx-clear-button {
  background: #ffffff;
  border: 1px solid #ff9d9d;
  color: #ff3333;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  cursor: pointer;
}

.rentx-clear-button:hover {
  background: #fff5f5;
}

.rentx-save-status {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #768093;
  font-size: 13px;
}

.rentx-save-check {
  color: #16a765;
  font-size: 14px;
}

.rentx-progress-track {
  width: 100%;
  height: 8px;
  margin-top: 10px;
  background: #e4e6e9;
  border-radius: 20px;
  overflow: hidden;
}

.rentx-progress-fill {
  width: 33.33%;
  height: 100%;
  background: #286c55;
  border-radius: 20px;
  transition: width .35s ease;
}

.rentx-step-wrapper {
  width: min(880px, calc(100% - 40px));
  margin: 28px auto 22px;
  padding: 8px;
  display: flex;
  gap: 6px;
  background: #f0dbc5;
  border-radius: 36px;
  border-bottom: 5px solid #000;
}

.rentx-step-button {
  flex: 1;
  height: 44px;
  border: none;
  border-radius: 28px;
  background: transparent;
  color: #526075;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: .2s;
}

.rentx-step-button.active {
  background: #ffffff;
  color: #182033;
  box-shadow: 0 5px 9px rgba(0, 0, 0, .12);
}

.rentx-property-form {
  width: min(880px, calc(100% - 40px));
  margin: 0 auto;
}

.rentx-form-panel {
  background: #faf7f4;
  border: 1px solid #111111;
  border-radius: 18px;
  padding: 24px 26px 28px;
}

.rentx-form-panel h2 {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 700;
}

.rentx-listing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 22px;
}

.rentx-listing-card {
  min-height: 92px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: #ffffff;
  border: 2px solid #dfe3e8;
  border-radius: 12px;
  cursor: pointer;
  transition: .2s;
}

.rentx-listing-card.selected {
  background: #f0ddc7;
  border-color: #286c55;
  box-shadow: 0 4px 8px rgba(0, 0, 0, .09);
}

.rentx-listing-card input {
  display: none;
}

.rentx-radio-circle {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 2px solid #d1d6de;
  position: relative;
}

.rentx-listing-card.selected .rentx-radio-circle {
  border-color: #286c55;
}

.rentx-listing-card.selected .rentx-radio-circle::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #286c55;
}

.rentx-listing-content h3 {
  margin: 0 0 3px;
  font-size: 15px;
  font-weight: 600;
}

.rentx-listing-content p {
  margin: 0;
  color: #7a8493;
  font-size: 12px;
}

.rentx-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 18px;
}

.rentx-form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rentx-form-field label {
  font-size: 13px;
  font-weight: 600;
}

.rentx-required {
  color: #ed3636;
}

.rentx-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  margin-left: 4px;
  border: 1.5px solid #aab2bd;
  border-radius: 50%;
  color: #8993a2;
  font-size: 10px;
}

.rentx-form-field input,
.rentx-form-field select {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border: 1.5px solid #dfe3e8;
  border-radius: 10px;
  outline: none;
  background: #ffffff;
  color: #34465b;
  font-size: 14px;
  transition: border-color .2s;
}

.rentx-form-field input:focus,
.rentx-form-field select:focus {
  border-color: #286c55;
}

.rentx-form-field input::placeholder {
  color: #a5a8ac;
}

.rentx-chip-grid {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.rentx-chip-option {
  padding: 9px 16px;
  border: 1.5px solid #dfe3e8;
  border-radius: 10px;
  background: #ffffff;
  font-size: 13px;
  font-weight: 500;
  color: #465365;
  cursor: pointer;
  transition: all 0.2s ease;
}

.rentx-chip-option.selected {
  background: #f0ddc7;
  border-color: #286c55;
  color: #1c5945;
  font-weight: 600;
}

.rentx-amenities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 6px;
}

.amenity-checkbox-card {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #ffffff;
  border: 1px solid #dfe3e8;
  padding: 10px 14px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  color: #243b53;
  transition: border-color 0.2s ease;
}

.amenity-checkbox-card:hover {
  border-color: #286c55;
}

.amenity-checkbox-card input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #286c55;
  cursor: pointer;
}

.rentx-textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #dfe3e8;
  border-radius: 10px;
  outline: none;
  background: #ffffff;
  color: #34465b;
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
}

.rentx-textarea:focus {
  border-color: #286c55;
}

.rentx-currency {
  position: relative;
}

.rentx-currency span {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #647184;
  font-size: 14px;
}

.rentx-currency input {
  padding-left: 32px;
}

.rentx-date {
  position: relative;
}

.rentx-date-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #3470a5;
  font-size: 15px;
  pointer-events: none;
}

.rentx-date input {
  padding-left: 38px;
  color: #497cad;
}

.rentx-broker-box {
  background: #ffffff;
  border: 1px solid #dfe3e8;
  border-radius: 14px;
  padding: 18px 20px 14px;
  margin: 6px 0 22px;
}

.rentx-broker-title {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 600;
}

.rentx-broker-option {
  height: 52px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  margin-bottom: 10px;
  background: #ffffff;
  border: 1.5px solid #dfe3e8;
  border-radius: 10px;
  cursor: pointer;
}

.rentx-broker-option.selected {
  border-color: #286c55;
  background: #f5fbf8;
}

.rentx-broker-option input {
  display: none;
}

.rentx-broker-radio {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #d1d6de;
  position: relative;
  flex-shrink: 0;
}

.rentx-broker-option.selected .rentx-broker-radio {
  border-color: #286c55;
}

.rentx-broker-option.selected .rentx-broker-radio::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 9px;
  background: #286c55;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.rentx-broker-option span:last-child {
  font-size: 13px;
}

.rentx-broker-note {
  margin: 2px 0 0;
  color: #7a8493;
  font-size: 12px;
}

.rentx-bhk-title {
  margin-bottom: 12px;
  font-size: 15px;
  font-weight: 600;
}

.rentx-bhk-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.rentx-bhk-option {
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 1px solid #dfe3e8;
  border-radius: 10px;
  color: #465365;
  font-size: 13px;
  cursor: pointer;
  transition: .2s;
}

.rentx-bhk-option:hover {
  border-color: #286c55;
}

.rentx-bhk-option.selected {
  background: #f0ddc7;
  border: 2px solid #286c55;
  color: #1c5945;
  font-weight: 600;
}

.rentx-bottom-actions {
  display: flex;
  gap: 10px;
  margin-top: 26px;
}

.rentx-cancel-button,
.rentx-proceed-button {
  min-width: 110px;
  height: 46px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: .2s;
}

.rentx-cancel-button {
  background: #ffffff;
  border: 1px solid #111111;
  color: #5b6676;
  box-shadow: 3px 3px 0 #000000;
}

.rentx-proceed-button {
  background: #286c55;
  border: 1px solid #111111;
  color: #ffffff;
  box-shadow: 3px 3px 0 #000000;
}

.rentx-cancel-button:hover,
.rentx-proceed-button:hover {
  transform: translateY(-1px);
}

.rentx-hidden {
  display: none !important;
}

.rentx-placeholder {
  min-height: 240px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.rentx-placeholder-icon {
  font-size: 38px;
  margin-bottom: 10px;
}

.rentx-placeholder p {
  max-width: 480px;
  color: #748093;
  font-size: 14px;
  line-height: 1.6;
}

.rentx-toast {
  position: fixed;
  left: 50%;
  bottom: 30px;
  transform: translate(-50%, 100px);
  background: #182033;
  color: #ffffff;
  padding: 14px 22px;
  border-radius: 10px;
  opacity: 0;
  transition: .25s;
  z-index: 9999;
}

.rentx-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ==========================================================================
   9. FOOTER COMPONENT (Footer Image 2)
   ========================================================================== */
.flatx-footer {
  background: #FFFFFF;
  border-top: 1px solid var(--border-light);
  padding: 4rem 2rem 2rem;
  position: relative;
  margin-top: 4rem;
}

.footer-container {
  max-width: 1450px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1.8fr 1fr 1fr 1fr 1fr;
  gap: 2rem;
  padding-bottom: 3rem;
}

.brand-slogan {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 0.8rem;
}

.address-text {
  font-size: 0.85rem;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.contact-details p {
  font-size: 0.85rem;
  color: #334155;
  margin-bottom: 0.2rem;
}

.email-link {
  color: #2563EB;
  text-decoration: underline;
}

.footer-heading {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 1.2rem;
}

.footer-links {
  list-style: none;
  padding: 0;
}

.footer-links li {
  margin-bottom: 0.6rem;
}

.footer-links a {
  color: #475569;
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--green-primary);
}

.social-icons {
  display: flex;
  gap: 0.8rem;
}

.social-icons a {
  color: #334155;
  transition: color 0.2s ease;
}

.social-icons a:hover {
  color: var(--green-primary);
}

.footer-bottom {
  border-top: 1px solid var(--border-light);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--green-primary);
  color: #fff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.2rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(30, 86, 65, 0.4);
  transition: background 0.2s ease;
  z-index: 999;
}

.back-to-top:hover {
  background: var(--green-hover);
}

/* ==========================================================================
   10. MODALS & OVERLAYS
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1; pointer-events: auto;
}

.modal-content {
  background: #fff;
  border-radius: 20px;
  max-width: 580px;
  width: 100%;
  padding: 2rem;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
}

.modal-close {
  position: absolute;
  top: 1rem; right: 1rem;
  border: none; background: #F1F5F9;
  width: 32px; height: 32px;
  border-radius: 50%; font-size: 1.2rem;
  cursor: pointer;
}

.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.3rem; }
.form-control { width: 100%; padding: 0.7rem 0.9rem; border: 1px solid #CBD5E1; border-radius: 8px; outline: none; font-size: 0.95rem; }

.btn-primary-green {
  background: var(--green-primary);
  color: #fff;
  border: none;
  padding: 0.75rem 1.4rem;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
}

/* ==========================================================================
   11. RESPONSIVE BREAKPOINTS
   ========================================================================== */
@media(max-width: 1024px) {
  .property-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-container { grid-template-columns: repeat(3, 1fr); }
  .hero-container { grid-template-columns: 1fr; text-align: center; }
  .rentx-progress-card, .rentx-step-wrapper, .rentx-property-form { width: calc(100% - 40px); }
  .rentx-progress-top { flex-direction: column; gap: 20px; }
  .rentx-listing-grid { grid-template-columns: 1fr; }
}

@media(max-width: 700px) {
  .container { width: calc(100% - 25px); }
  h1.main-heading { font-size: 38px; }
  .search-top { flex-direction: column; align-items: stretch; gap: 8px; }
  .search-input { height: 48px; }
  .filters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .filters select { width: 100%; font-size: 13px; height: 42px; padding: 0 10px; }
  .filter-button { width: 100%; height: 42px; font-size: 13px; }
  .filters .search-button { grid-column: 1 / -1; height: 44px; margin-top: 4px; }
  .filters .view-buttons { grid-column: 1 / -1; height: 44px; }
  .view-buttons { min-width: 100%; }
  .property-grid { grid-template-columns: 1fr; }
  .footer-container { grid-template-columns: 1fr; }
  .header-nav { display: none; }
  .timeline-line { left: 20px; }
  .timeline-step { flex-direction: column !important; text-align: left; }
  .step-media, .step-card { width: 100%; }
  .referral-card { flex-direction: column; align-items: flex-start; gap: 22px; width: 100%; }
  .copy-button, .whatsapp-button { width: 100%; justify-content: center; }
  .rentx-progress-card, .rentx-step-wrapper, .rentx-property-form { width: calc(100% - 24px); }
  .rentx-progress-card { padding: 16px 16px 22px; border-radius: 18px; }
  .rentx-progress-title h1 { font-size: 21px; }
  .rentx-step-wrapper { margin-top: 20px; padding: 8px; border-radius: 24px; overflow-x: auto; }
  .rentx-step-button { min-width: 140px; height: 42px; font-size: 13px; }
  .rentx-form-panel { padding: 18px 16px; }
  .rentx-form-grid { grid-template-columns: 1fr; }
  .rentx-bhk-grid { grid-template-columns: repeat(2, 1fr); }
  .rentx-bottom-actions { flex-direction: column; }
  .rentx-cancel-button, .rentx-proceed-button { width: 100%; }
  .rentx-amenities-grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   12. FLATX PRO PLAN MODAL
   ========================================================================== */
.pro-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2500;
  background: rgba(0, 0, 0, 0.80);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.25s ease;
}

.pro-overlay.hidden {
  display: none !important;
}

.pro-modal {
  width: 560px;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  background: #fff5e8;
  position: relative;
  overflow: hidden;
  border-radius: 0;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
  font-family: Arial, Helvetica, sans-serif;
}

.pro-modal-scroll {
  width: 100%;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 28px 38px 35px;
  scrollbar-color: #898989 #eee;
  scrollbar-width: auto;
}

.pro-modal-scroll::-webkit-scrollbar {
  width: 14px;
}

.pro-modal-scroll::-webkit-scrollbar-track {
  background: #eee;
}

.pro-modal-scroll::-webkit-scrollbar-thumb {
  background: #898989;
  border-radius: 10px;
  border: 2px solid #eee;
}

.pro-close-btn {
  position: absolute;
  z-index: 20;
  top: 25px;
  right: 28px;
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: #286b55;
  font-size: 34px;
  font-weight: 300;
  line-height: 20px;
  padding: 0;
  cursor: pointer;
}

.pro-close-btn:hover {
  color: #123f31;
}

.pro-modal-header {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 44px;
}

.pro-modal-logo {
  font-size: 28px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -2px;
  color: #111111;
}

.pro-modal-logo span {
  color: #064b3a;
}

.pro-modal-badge {
  background: linear-gradient(135deg, #464646, #111111);
  color: #f4ad2c;
  padding: 9px 16px;
  border-radius: 22px;
  font-size: 18px;
  font-weight: 700;
}

.pro-title {
  margin: 0;
  max-width: 400px;
  font-size: 25px;
  line-height: 1.55;
  font-weight: 700;
  color: #111111;
}

.pro-subtitle {
  margin: 12px 0 0;
  color: #666666;
  font-size: 15px;
  line-height: 1.5;
}

.pro-trial {
  display: inline-block;
  margin-top: 32px;
  color: #286b55;
  font-size: 16px;
  font-weight: 700;
  padding-bottom: 3px;
  border-bottom: 1px solid #286b55;
}

.pro-card-container {
  width: 395px;
  max-width: 100%;
  margin: 50px auto 0;
  padding-right: 8px;
  padding-bottom: 8px;
}

.pro-price-card {
  position: relative;
  width: 100%;
  padding: 28px 21px 18px;
  border-radius: 15px;
  background: linear-gradient(145deg, #414141, #2e2e2e);
  color: #ffffff;
  box-shadow: 8px 8px 0 #efae64;
}

.pro-price-card::after {
  content: "";
  position: absolute;
  top: 10px;
  right: -8px;
  width: 8px;
  height: calc(100% - 20px);
  background: #efae64;
  border-radius: 0 10px 10px 0;
}

.pro-access-label {
  color: #ffb62f;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 17px;
}

.pro-price {
  margin: 0;
  font-size: 40px;
  line-height: 1;
  font-weight: 800;
  color: #ffffff;
}

.pro-access-description {
  margin-top: 17px;
  margin-bottom: 25px;
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.pro-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 25px;
  row-gap: 13px;
  margin-bottom: 24px;
}

.pro-feature {
  display: grid;
  grid-template-columns: 17px 1fr;
  column-gap: 7px;
  color: #e8e8e8;
  font-size: 14px;
  line-height: 1.45;
}

.pro-check {
  font-size: 16px;
  color: #ffffff;
}

.pro-unlock-btn {
  width: 100%;
  height: 49px;
  border: none;
  border-radius: 7px;
  background: #ffffff;
  color: #286b55;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 5px 5px 0 #0ca16e;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.pro-unlock-btn:hover {
  transform: translateY(-1px);
}

.pro-unlock-btn:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #0ca16e;
}

.pro-unlock-btn.unlocked {
  background: #286b55;
  color: #ffffff;
}

.pro-payment-security {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 50px;
  padding-bottom: 25px;
  color: #6b9989;
  font-size: 14px;
}

.pro-security-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #e8e5d4;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #286b55;
  font-size: 18px;
}

.pro-success-message {
  display: none;
  margin-top: 10px;
  padding: 12px;
  background: #dff3e9;
  color: #286b55;
  border-radius: 8px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
}

.pro-success-message.show {
  display: block;
}

@media (max-width: 600px) {
  .pro-modal-scroll {
    padding-left: 24px;
    padding-right: 24px;
  }

  .pro-card-container {
    width: 100%;
  }

  .pro-title {
    font-size: 22px;
  }
}

/* ==========================================================================
   RESPONSIVE LAYOUT ENGINE (Mobile, Tablet & Laptop Breakpoints)
   ========================================================================== */

/* Mobile Hamburger Menu Toggle Styling */
.mobile-nav-toggle {
  display: none;
  background: transparent;
  border: 2px solid #1E293B;
  color: #1E293B;
  font-size: 24px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 10px;
  cursor: pointer;
  line-height: 1;
}

/* TABLET & MOBILE RESPONSIVE (max-width: 1024px) */
@media (max-width: 1024px) {
  .flatx-header {
    padding: 0.6rem 1.2rem;
  }

  .brand-logo-img {
    height: 48px;
  }

  .mobile-nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    margin-right: 12px;
  }

  .header-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 2px solid #111111;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 16px;
    box-shadow: 0 12px 24px rgba(0,0,0,0.12);
  }

  .header-nav.mobile-active {
    display: flex;
  }

  .header-nav .nav-item {
    padding: 12px 16px;
    font-size: 1rem;
    border-bottom: 1px solid #f1f5f9;
    border-radius: 8px;
    justify-content: flex-start;
  }

  .header-nav .nav-item:last-child {
    border-bottom: none;
  }

  .container {
    width: calc(100% - 32px);
  }

  /* Hero Section */
  .hero-container {
    flex-direction: column;
    text-align: center;
    gap: 30px;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-title {
    font-size: 2.4rem;
  }

  .search-box-wrap {
    max-width: 100%;
  }

  .hero-graphic {
    max-width: 320px;
    margin: 0 auto;
  }

  /* Property Search Grid */
  .property-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.2rem;
  }

  .search-top {
    flex-direction: column;
    gap: 14px;
    align-items: stretch;
  }

  .search-input {
    width: 100%;
  }

  .view-buttons {
    height: 52px;
  }

  .view-buttons button {
    flex: 1;
    justify-content: center;
    padding: 0 10px;
  }
}

/* MOBILE PHONES RESPONSIVE (max-width: 640px) */
@media (max-width: 640px) {
  .brand-logo-img {
    height: 42px;
  }

  .pro-badge {
    display: none;
  }

  .hero-title {
    font-size: 1.8rem;
  }

  .hero-subtitle {
    font-size: 0.95rem;
  }

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

  .reviews-title {
    font-size: 1.6rem;
  }

  .review-card {
    flex: 0 0 280px;
    padding: 1.2rem;
  }

  .carousel-nav-btn {
    width: 36px;
    height: 36px;
    font-size: 18px;
  }

  .admin-stats-grid {
    grid-template-columns: 1fr;
  }

  .admin-header-bar {
    padding: 14px 16px;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
  }

  .admin-user-info {
    width: 100%;
    justify-content: space-between;
  }
}

/* Google Login Button Styles */
.login-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 22px 0;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 800;
}

.login-divider::before, .login-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1.5px solid #e2e8f0;
}

.login-divider span {
  padding: 0 14px;
}

.google-login-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #ffffff;
  color: #0f172a;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.google-login-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

/* Interest Modal Styling */
.interest-modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
    z-index: 4000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.interest-modal-overlay.active {
    display: flex;
}

.interest-modal-box {
    background: #ffffff;
    width: 100%;
    max-width: 520px;
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}

.interest-close-btn {
    position: absolute;
    top: 20px;
    right: 24px;
    background: #f1f5f9;
    border: none;
    font-size: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #475569;
}

.interest-badge {
    background: #FFFBEB;
    color: #D97706;
    border: 1px solid #FDE68A;
    font-size: 11px;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 12px;
    display: inline-block;
    margin-bottom: 10px;
}

.interest-form-group {
    margin-bottom: 16px;
}

.interest-form-group label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    margin-bottom: 6px;
}

.interest-form-group input,
.interest-form-group select,
.interest-form-group textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    font-size: 14px;
    outline: none;
}

.interest-form-group input:focus,
.interest-form-group select:focus,
.interest-form-group textarea:focus {
    border-color: #F5A623;
}

.interest-submit-btn {
    width: 100%;
    background: #0f172a;
    color: #F5A623;
    border: none;
    padding: 14px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    margin-top: 10px;
    transition: background 0.2s ease;
}

.interest-submit-btn:hover {
    background: #d97706;
    color: #ffffff;
}

/* ==========================================================================
   SPLIT SCREEN MAP VIEW & INTERACTIVE PILL MARKERS (Screenshot UI Match)
   ========================================================================== */

.flats-split-layout {
  display: flex;
  gap: 20px;
  position: relative;
  align-items: flex-start;
  transition: all 0.3s ease;
}

.flats-split-layout .property-grid-wrap {
  flex: 1;
  min-width: 0;
}

.flats-split-layout.split-active .property-grid-wrap {
  flex: 0 0 52%;
}

.flats-split-layout.split-active .property-grid {
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 1rem;
}

.map-view-column {
  display: none;
  flex: 0 0 48%;
  height: calc(100vh - 120px);
  position: sticky;
  top: 90px;
  border-radius: 20px;
  overflow: hidden;
  border: 1.5px solid #e2e8f0;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  background: #f8fafc;
}

.flats-split-layout.split-active .map-view-column {
  display: block;
}

#leafletMapContainer {
  width: 100%;
  height: 100%;
  min-height: 450px;
  z-index: 1;
  display: block;
}

/* Custom Dark Pill Markers (Matching Screenshot) */
.leaflet-pill-marker {
  background: #0f172a;
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 800;
  font-family: 'Plus Jakarta Sans', sans-serif;
  border: 2px solid #ffffff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  white-space: nowrap;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.leaflet-pill-marker:hover, .leaflet-pill-marker.active {
  background: #F5A623;
  color: #0f172a;
  transform: scale(1.1);
  z-index: 1000 !important;
}

.leaflet-pill-marker.blue-pin {
  background: #2563eb;
  color: #ffffff;
}

.map-floating-bar {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1000;
  display: flex;
  gap: 8px;
}

.map-floating-btn {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  padding: 7px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.map-floating-btn:hover {
  background: #0f172a;
  color: #ffffff;
}

/* Mobile Responsiveness for Split Map */
@media (max-width: 992px) {
  .flats-split-layout.split-active {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px;
  }

  .flats-split-layout.split-active .property-grid-wrap {
    display: none; /* Hide property list initially on mobile when Map tab is active */
  }

  .flats-split-layout.split-active.show-properties .property-grid-wrap {
    display: block !important; /* Show property cards when user touches a location pin! */
    animation: fadeInGrid 0.3s ease;
  }

  @keyframes fadeInGrid {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .flats-split-layout.split-active .property-grid-wrap,
  .flats-split-layout.split-active .map-view-column {
    flex: 1 0 100%;
    width: 100%;
  }

  .flats-split-layout.split-active .map-view-column {
    display: block !important;
    height: 480px !important;
    min-height: 480px !important;
    position: relative;
    top: 0;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.18);
    border: 2px solid #F5A623;
    margin-bottom: 16px;
    background: #e2e8f0;
  }

  .map-view-column.mobile-fullscreen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 99999 !important;
    border-radius: 0 !important;
    margin: 0 !important;
  }

  .flats-split-layout.split-active .property-grid {
    grid-template-columns: 1fr !important;
  }

  .map-floating-bar {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    gap: 8px;
  }
}

/* ==========================================================================
   AI CHAT ASSISTANT & PROPERTY COMPARISON MATRIX
   ========================================================================== */

/* ==========================================================================
   GLOBAL PREMIUM MODAL SYSTEM (.admin-modal & OVERLAYS)
   ========================================================================== */

.admin-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.admin-modal.active {
  display: flex !important;
  animation: modalFadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.admin-modal-box {
  background: #ffffff;
  color: #0f172a;
  width: 100%;
  max-width: 640px;
  border-radius: 24px;
  padding: 35px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid #e2e8f0;
}

.admin-form-group {
  margin-bottom: 20px;
  text-align: left;
}

.admin-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: #334155;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-form-group input,
.admin-form-group select,
.admin-form-group textarea {
  width: 100%;
  padding: 13px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  font-size: 15px;
  outline: none;
  font-family: 'Plus Jakarta Sans', sans-serif;
  color: #0f172a;
  background: #f8fafc;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.admin-form-group input:focus,
.admin-form-group select:focus,
.admin-form-group textarea:focus {
  border-color: #F5A623;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.15);
}

.admin-upload-box {
  border: 2px dashed #cbd5e1;
  padding: 25px;
  border-radius: 16px;
  background: #f8fafc;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.admin-upload-box:hover {
  border-color: #F5A623;
  background: #fffdf5;
}

/* AI Chat Floating Bubble */
.ai-chat-bubble {
  position: fixed;
  bottom: 90px;
  right: 24px;
  z-index: 5000;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #F5A623;
  border: 2px solid #F5A623;
  width: 65px;
  height: 65px;
  padding: 0;
  border-radius: 50%;
  overflow: hidden;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.ai-chat-bubble:hover {
  transform: scale(1.05);
  box-shadow: 0 14px 30px rgba(0,0,0,0.4);
}

.ai-chat-window {
  display: none;
  position: fixed;
  bottom: 155px;
  right: 24px;
  width: 380px;
  height: 520px;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.25);
  border: 1.5px solid #cbd5e1;
  z-index: 5000;
  flex-direction: column;
  overflow: hidden;
}

.ai-chat-window.active {
  display: flex;
}

.ai-chat-header {
  background: #0f172a;
  color: #ffffff;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-chat-messages {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ai-msg {
  max-width: 85%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.5;
}

.ai-msg-bot {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #e2e8f0;
  align-self: flex-start;
  box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

.ai-msg-user {
  background: #0f172a;
  color: #ffffff;
  align-self: flex-end;
}

.ai-chat-input-area {
  padding: 12px;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  display: flex;
  gap: 8px;
}

.ai-chat-input-area input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  outline: none;
  font-size: 13px;
}

.ai-chat-input-area button {
  background: #F5A623;
  color: #0f172a;
  border: none;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 800;
  cursor: pointer;
}

/* Property Comparison Floating Bar */
.compare-floating-bar {
  display: none;
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4500;
  background: #0f172a;
  color: #ffffff;
  padding: 12px 24px;
  border-radius: 30px;
  border: 2px solid #F5A623;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  align-items: center;
  gap: 16px;
}

.compare-floating-bar.active {
  display: flex;
}

.compare-btn-action {
  background: #F5A623;
  color: #0f172a;
  border: none;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: 800;
  font-size: 13px;
  cursor: pointer;
}

/* NOTIFICATION BELL ICON & DRAWER SYSTEM */
.notification-bell-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  color: #0f172a;
}

.notification-bell-btn:hover {
  background: #0f172a;
  color: #F5A623;
  border-color: #0f172a;
}

.notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: #ef4444;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  border-radius: 10px;
  padding: 2px 6px;
  border: 2px solid #ffffff;
  line-height: 1;
}

.notification-drawer {
  display: none;
  position: absolute;
  top: 50px;
  right: 0;
  width: 320px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.25);
  border: 1.5px solid #cbd5e1;
  z-index: 9999;
  overflow: hidden;
  animation: notifFadeIn 0.2s ease;
}

.notification-drawer.active {
  display: block !important;
}

@keyframes notifFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.notif-header {
  padding: 14px 18px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notif-list {
  max-height: 320px;
  overflow-y: auto;
}

.notif-item {
  padding: 12px 16px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: background 0.2s ease;
}

.notif-item:hover {
  background: #f8fafc;
}

.notif-item.unread {
  background: #fffdf5;
}

.notif-icon {
  font-size: 18px;
}

.notif-content strong {
  display: block;
  font-size: 13px;
  color: #0f172a;
  margin-bottom: 2px;
}

.notif-content p {
  margin: 0;
  font-size: 12px;
  color: #475569;
}

.notif-time {
  display: block;
  font-size: 10px;
  color: #94a3b8;
  margin-top: 4px;
  font-weight: 700;
}

/* ==========================================================================
   STATIC CONTENT PAGES (FAQ, Contact, Terms, Privacy, Opt-out, Resources,
   Pricing) — one shared look for every simple text/info page on the site.
   ========================================================================== */
.legal-page { max-width: 860px; margin: 0 auto; padding: 56px 20px 80px; }
.legal-eyebrow {
  display: inline-block; font-size: 12px; font-weight: 800; letter-spacing: 1.5px;
  color: #d97706; background: rgba(245,166,35,0.12); padding: 6px 14px;
  border-radius: 999px; margin-bottom: 16px; text-transform: uppercase;
}
.legal-title { font-size: 34px; font-weight: 800; color: #0f172a; line-height: 1.2; margin: 0 0 12px; }
.legal-sub { font-size: 16px; color: #64748b; font-weight: 500; line-height: 1.65; margin: 0 0 40px; }
.legal-updated { font-size: 13px; color: #94a3b8; font-weight: 600; margin: 0 0 32px; }
.legal-section { margin-bottom: 36px; }
.legal-section h2 { font-size: 20px; font-weight: 800; color: #0f172a; margin: 0 0 14px; }
.legal-section h3 { font-size: 16px; font-weight: 800; color: #1e293b; margin: 20px 0 8px; }
.legal-section p { font-size: 15px; color: #475569; line-height: 1.75; font-weight: 500; margin: 0 0 14px; }
.legal-section ul, .legal-section ol { margin: 0 0 14px; padding-left: 22px; }
.legal-section li { font-size: 15px; color: #475569; line-height: 1.75; font-weight: 500; margin-bottom: 8px; }
.legal-section a { color: #d97706; font-weight: 700; text-decoration: none; }
.legal-section a:hover { text-decoration: underline; }
.legal-card {
  background: #ffffff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 24px 26px;
  box-shadow: 0 2px 8px rgba(15,23,42,0.04); margin-bottom: 18px;
}
.legal-toc {
  background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 14px; padding: 18px 22px;
  margin-bottom: 40px;
}
.legal-toc h4 { font-size: 12px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase; color: #64748b; margin: 0 0 10px; }
.legal-toc ul { margin: 0; padding-left: 20px; columns: 2; }
.legal-toc li { font-size: 13.5px; margin-bottom: 6px; }
.legal-toc a { color: #334155; font-weight: 700; text-decoration: none; }
.legal-toc a:hover { color: #d97706; }

/* FAQ accordion */
.faq-item { border: 1px solid #e2e8f0; border-radius: 12px; margin-bottom: 12px; overflow: hidden; background: #fff; }
.faq-question {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 20px; cursor: pointer; font-weight: 700; font-size: 15px; color: #0f172a;
  background: none; border: none; width: 100%; text-align: left; font-family: inherit;
}
.faq-question:hover { background: #f8fafc; }
.faq-icon { flex-shrink: 0; transition: transform 0.2s ease; color: #d97706; font-size: 18px; font-weight: 800; }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.25s ease; }
.faq-item.open .faq-answer { max-height: 500px; }
.faq-answer-inner { padding: 0 20px 18px; font-size: 14.5px; color: #64748b; line-height: 1.7; font-weight: 500; }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 40px; }
.contact-method {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 22px;
  display: flex; gap: 14px; align-items: flex-start; box-shadow: 0 2px 8px rgba(15,23,42,0.04);
}
.contact-method-icon {
  width: 42px; height: 42px; border-radius: 10px; background: rgba(245,166,35,0.12);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: #d97706;
}
.contact-method h3 { font-size: 14px; font-weight: 800; color: #0f172a; margin: 0 0 4px; }
.contact-method a, .contact-method p { font-size: 14px; color: #475569; font-weight: 600; margin: 0; text-decoration: none; }
.contact-method a:hover { color: #d97706; }

/* Pricing */
.pricing-hero-card {
  background: linear-gradient(135deg, #0f172a, #1e293b); color: #fff; border-radius: 20px;
  padding: 40px 32px; text-align: center; margin-bottom: 36px;
}
.pricing-hero-card .price-tag { font-size: 48px; font-weight: 800; color: #F5A623; margin: 12px 0; }
.pricing-hero-card p { color: #cbd5e1; font-size: 15px; font-weight: 500; max-width: 480px; margin: 0 auto; }
.pricing-feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.pricing-feature {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 18px 20px;
  font-size: 14px; font-weight: 700; color: #0f172a; display: flex; align-items: center; gap: 10px;
}
.pricing-feature .check { color: #10b981; font-size: 18px; flex-shrink: 0; }

/* Opt-out */
.optout-steps { counter-reset: optout; margin: 24px 0; }
.optout-step { display: flex; gap: 16px; margin-bottom: 20px; align-items: flex-start; }
.optout-num {
  width: 32px; height: 32px; border-radius: 50%; background: #0f172a; color: #F5A623;
  display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; flex-shrink: 0;
}
.optout-step-text h3 { font-size: 15px; font-weight: 800; color: #0f172a; margin: 0 0 4px; }
.optout-step-text p { font-size: 14px; color: #64748b; font-weight: 500; margin: 0; }

/* Resources */
.resources-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.resource-card {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 24px;
  box-shadow: 0 2px 8px rgba(15,23,42,0.04); transition: all 0.2s ease;
}
.resource-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(15,23,42,0.1); }
.resource-card .resource-icon { font-size: 26px; margin-bottom: 12px; }
.resource-card h3 { font-size: 15.5px; font-weight: 800; color: #0f172a; margin: 0 0 8px; }
.resource-card p { font-size: 13.5px; color: #64748b; font-weight: 500; line-height: 1.6; margin: 0; }

@media (max-width: 640px) {
  .contact-grid { grid-template-columns: 1fr; }
  .legal-toc ul { columns: 1; }
  .legal-title { font-size: 26px; }
}


.brand-text { font-size: 1.6rem; font-weight: 800; color: #1E293B; margin-left: 8px; font-family: 'Poppins', sans-serif; letter-spacing: -0.5px; }

.brand-x { color: #F5A623; }





/* ==========================================================================
   MODERN LISTING CARD (Browse grid) — js/app.js displayProperties()
   ========================================================================== */
.property-card.rh-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid #eceef2;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 6px 20px rgba(15, 23, 42, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.property-card.rh-card:hover {
  transform: translateY(-4px);
  border-color: #e2e5ea;
  box-shadow: 0 2px 4px rgba(15, 23, 42, 0.05), 0 16px 36px rgba(15, 23, 42, 0.10);
}

/* Photo */
.rh-card .rh-card-media {
  position: relative;
  height: auto;
  aspect-ratio: 16 / 11;
  overflow: hidden;
  cursor: pointer;
  background: #f1f5f9;
}
.rh-card .rh-card-media > img,
.rh-card .rh-card-media > video { width: 100%; height: 100%; object-fit: cover; }
.rh-card-slides {
  display: flex;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.rh-card-slides::-webkit-scrollbar { display: none; }
.rh-card-slide { position: relative; flex: 0 0 100%; height: 100%; scroll-snap-align: start; }
.rh-card-slide img, .rh-card-slide video { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; }
.rh-card:hover .rh-card-slide img,
.rh-card:hover .rh-card-media > img { transform: scale(1.03); }
.rh-card .rh-card-media::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 40%;
  background: linear-gradient(to top, rgba(15, 23, 42, 0.35), rgba(15, 23, 42, 0));
  pointer-events: none;
}

.rh-card-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  gap: 6px;
  z-index: 3;
  pointer-events: none;
}
.rh-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.94);
  color: #0f172a;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 9px;
  border-radius: 999px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
  backdrop-filter: blur(6px);
}
.rh-badge svg { width: 12px; height: 12px; }
.rh-badge--verified { color: #047857; }

.rh-card .rh-card-heart {
  top: 10px;
  right: 10px;
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.94);
  color: #0f172a;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.18);
  z-index: 3;
}
.rh-card .rh-card-heart svg { width: 18px; height: 18px; }

.rh-card-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.92);
  color: #0f172a;
  font-size: 22px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  opacity: 0;
  transition: opacity 0.15s ease;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.2);
}
.rh-card-nav--prev { left: 10px; }
.rh-card-nav--next { right: 10px; }
.rh-card:hover .rh-card-nav { opacity: 1; }
@media (hover: none) { .rh-card-nav { display: none; } }

.rh-card-count {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 3;
  background: rgba(15, 23, 42, 0.62);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  pointer-events: none;
}

/* Body */
.rh-card .rh-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 16px 18px 18px;
}
.rh-card .rh-card-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  color: #0f172a;
  margin: 0 0 4px;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rh-card .rh-card-title:hover { color: #b45309; }
.rh-card-location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: #64748b;
  min-width: 0;
}
.rh-card-location svg { width: 14px; height: 14px; flex: 0 0 14px; margin: 0 !important; }
.rh-card-location span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.rh-card-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}
.rh-card-facts span {
  font-size: 12px;
  font-weight: 600;
  color: #334155;
  background: #f1f5f9;
  padding: 4px 10px;
  border-radius: 999px;
}

.rh-card-price {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #f1f5f9;
}
.rh-card-price-main {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.01em;
}
.rh-card-price-main small { font-size: 13px; font-weight: 600; color: #64748b; letter-spacing: 0; }
.rh-card-price-main .rh-from { margin-right: 4px; }
.rh-card-price-sub { font-size: 13px; color: #64748b; margin-top: 2px; }

.rh-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 12px;
  color: #94a3b8;
}
.rh-card-meta-good { display: inline-flex; align-items: center; gap: 4px; color: #059669; font-weight: 700; }
.rh-card-meta svg { width: 13px; height: 13px; margin: 0 !important; }

.rh-card-owner-edit {
  width: 100%;
  margin-top: 10px;
  background: #fffbeb;
  color: #92400e;
  border: 1px solid #fde68a;
  padding: 8px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
}

/* Actions — pinned to the bottom so every card in a row lines up */
.rh-card-actions { margin-top: auto; padding-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.rh-card-actions-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rh-card-ghost,
.rh-card-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.rh-card-ghost svg, .rh-card-cta svg { width: 15px; height: 15px; margin: 0 !important; }
.rh-card-ghost {
  height: 38px;
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #e2e8f0;
}
.rh-card-ghost:hover { background: #f8fafc; border-color: #cbd5e1; }
.rh-card-cta {
  height: 44px;
  border: none;
  font-size: 14px;
}
.rh-card-cta--loading { background: #f1f5f9; color: #94a3b8; cursor: default; }
.rh-card-cta--primary { background: #0f172a; color: #ffffff; }
.rh-card-cta--primary:hover { background: #1e293b; box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18); }
.rh-card-cta--pro { background: #F5A623; color: #0f172a; }
.rh-card-cta--pro:hover { background: #e8971a; box-shadow: 0 6px 16px rgba(245, 166, 35, 0.3); }
.rh-card-cta--done { background: #ecfdf5; color: #047857; cursor: default; }

@media (max-width: 480px) {
  .rh-card .rh-card-body { padding: 14px 14px 16px; }
  .rh-card .rh-card-title { font-size: 17px; }
  .rh-card-price-main { font-size: 20px; }
}

/* ==========================================================================
   MOBILE POLISH (phones) — layout fixes found in a page-by-page audit
   ========================================================================== */

/* Home: "Property Options in Top Cities" link grid (used to force a 472px-wide page on phones) */
.rh-city-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 320px)); gap: 8px 32px; }
@media (max-width: 600px) { .rh-city-grid { grid-template-columns: 1fr; gap: 0; } }

/* Contact / Opt-out: two inputs side by side, stacked on phones */
.rh-form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.rh-form-2col > * { min-width: 0; width: 100%; box-sizing: border-box; }
@media (max-width: 520px) { .rh-form-2col { grid-template-columns: 1fr; } }

/* Floating buttons (all screen sizes): WhatsApp bottom-right with Millie
   stacked directly above it, back-to-top on its own in the bottom-left —
   they used to pile up side by side in the bottom-right corner. */
.rh-wa-float {
  width: 60px !important;
  height: 60px !important;
  right: 22px !important;
  bottom: 24px !important;
  border-radius: 50% !important;
  background-color: #25D366 !important;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.22) !important;
}
/* The glyph drawn inline in index.php/flats.php is a thin hand-traced
   outline; swap it for the standard WhatsApp mark here so both pages get
   the same icon, sized and centred against the round button. */
.rh-wa-float svg { display: none; }
.rh-wa-float::before {
  content: "";
  width: 34px;
  height: 34px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23fff' d='M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.ai-chat-bubble { width: 60px; height: 60px; right: 22px; bottom: 92px; }
.ai-chat-window { bottom: 164px; }
.back-to-top {
  right: auto;
  left: 24px;
  bottom: 24px;
  background: #0f172a;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.25);
}
.back-to-top:hover { background: #1e293b; }
/* Pages without the WhatsApp button: Millie takes the corner itself */
body:not(:has(.rh-wa-float)) .ai-chat-bubble { bottom: 24px; }
body:not(:has(.rh-wa-float)) .ai-chat-window { bottom: 96px; }

@media (max-width: 600px) {
  /* Never let one stray element widen the whole page sideways */
  html, body { overflow-x: clip; }

  /* Browse: smaller page title */
  h1.main-heading { font-size: 26px !important; line-height: 1.25; margin-bottom: 16px; }

  /* Browse: compact filter panel */
  .search-box { padding: 14px !important; border-radius: 16px !important; }
  .search-box .search-top { flex-direction: column; align-items: stretch; gap: 10px; }
  .search-box .search-input { width: 100%; }
  .search-box .search-input input { font-size: 14px; }
  .search-box .sort { display: flex; align-items: center; gap: 8px; width: 100%; }
  .search-box .sort span { white-space: nowrap; font-size: 13px; }
  .search-box .sort select { flex: 1; min-width: 0; }
  .search-box .filters { display: grid !important; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
  .search-box .filters > select,
  .search-box .filters > button { width: 100%; min-width: 0; font-size: 13px; }
  .search-box .filters .view-buttons { grid-column: 1 / -1; min-width: 0; width: 100%; display: flex; }
  .search-box .filters .view-buttons button { flex: 1; justify-content: center; }
  .search-box .sort select,
  .search-box .filters > select { height: 44px; padding-top: 0; padding-bottom: 0; }
  .search-box .filters .search-button { grid-column: auto; margin-top: 0; height: 44px; }
  .search-box .filters .filter-button { height: 44px; }
  .search-box select { text-overflow: ellipsis; }

  /* Floating buttons on phones: smaller versions of the layout below */
  .rh-wa-float {
    width: 52px !important;
    height: 52px !important;
    right: 14px !important;
    bottom: 14px !important;
  }
  .rh-wa-float::before { width: 30px; height: 30px; }
  .ai-chat-bubble { width: 52px; height: 52px; right: 14px; bottom: 74px; border-width: 2px; }
  body:not(:has(.rh-wa-float)) .ai-chat-bubble { bottom: 14px; }
  body:not(:has(.rh-wa-float)) .ai-chat-window { bottom: 76px; }
  .back-to-top { left: 14px; bottom: 14px; width: 42px; height: 42px; }
  .ai-chat-window {
    left: 10px;
    right: 10px;
    width: auto;
    bottom: 136px;
    height: min(70vh, 520px);
  }
}

/* Home "How it works": the wave was meant to sit flush on the section's top
   edge (white page above flowing into the cream section) — unstyled, it
   floated inside the padding as a stray white bar. */
.how-it-works-section { position: relative; }
.wave-divider-top {
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  line-height: 0;
  pointer-events: none;
  z-index: 1;
}
.wave-divider-top svg { display: block; width: 100%; height: 60px; }
@media (max-width: 600px) { .wave-divider-top svg { height: 34px; } }

/* ==========================================================================
   HOME — "What our users say!" (modern review cards)
   ========================================================================== */
.testimonials-container .reviews-title { text-align: center; margin-bottom: 1.5rem; }
.testimonials-container .reviews-carousel {
  gap: 20px;
  padding: 12px 4px 24px;
  align-items: stretch;
  scroll-snap-type: x mandatory;
}
.testimonials-container .review-card.rh-review {
  flex: 0 0 calc((100% - 40px) / 3);
  max-width: none;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid #eceef2;
  border-radius: 18px;
  padding: 24px 22px 20px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 6px 20px rgba(15, 23, 42, 0.05);
  scroll-snap-align: start;
  transform: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.testimonials-container .review-card.rh-review:hover,
.testimonials-container .review-card.rh-review.active {
  border: 1px solid #eceef2;
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgba(15, 23, 42, 0.05), 0 16px 36px rgba(15, 23, 42, 0.09);
}
.rh-review-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.rh-review-stars { color: #f59e0b; font-size: 16px; letter-spacing: 2px; }
.rh-review-quote { color: #fde7c2; }
.rh-review .review-heading { font-size: 17px; font-weight: 800; color: #0f172a; margin: 0 0 8px; }
.rh-review .review-text { font-size: 14px; line-height: 1.65; color: #475569; margin: 0 0 18px; }
.rh-review-user {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}
.rh-review .review-avatar {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f5a623, #ec4899);
  color: #ffffff;
  font-weight: 800;
  font-size: 16px;
}
.rh-review-who { display: flex; flex-direction: column; min-width: 0; }
.rh-review-who strong { font-size: 14px; color: #0f172a; }
.rh-review-who span { font-size: 12px; line-height: 1.35; color: #64748b; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rh-review-verified {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 700;
  color: #047857;
  background: #ecfdf5;
  padding: 4px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.rh-review-verified svg { width: 12px; height: 12px; margin: 0 !important; }

/* Arrows: clean white circles (were heavy black offset-shadow buttons) */
.testimonials-container .carousel-nav-btn {
  width: 40px;
  height: 40px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  font-size: 22px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
}
.testimonials-container .carousel-nav-btn:hover { background: #0f172a; color: #ffffff; border-color: #0f172a; box-shadow: 0 6px 16px rgba(15, 23, 42, 0.2); }
.testimonials-container .dot.active { background: #f5a623; }

@media (max-width: 1024px) {
  .testimonials-container .review-card.rh-review { flex-basis: calc((100% - 20px) / 2); }
}
@media (max-width: 640px) {
  .testimonials-container .reviews-title { font-size: 26px; margin-bottom: 0.75rem; }
  .testimonials-container .reviews-carousel-wrapper { padding: 0; }
  .testimonials-container .reviews-carousel { padding: 10px 2px 18px; gap: 12px; align-items: flex-start; }
  .testimonials-container .review-card.rh-review { flex-basis: 88%; min-width: 0; padding: 20px 18px 18px; scroll-snap-align: center; }
  .testimonials-container .rh-review .review-text { margin-bottom: 14px; }
  .testimonials-container .carousel-nav-btn { display: none !important; }
}

/* ==========================================================================
   MILLIE — assistant chat (js/app.js initAiChatAssistant)
   ========================================================================== */
.ai-chat-window.millie {
  width: 380px;
  height: min(600px, calc(100vh - 260px));
  min-height: 360px;
  border: 1px solid #e8ebf0;
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
  background: #ffffff;
  font-family: inherit;
  transform-origin: bottom right;
}
.ai-chat-window.millie.active { animation: millieIn 0.18s ease-out; }
@keyframes millieIn { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: none; } }

.millie-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px 14px 16px;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #ffffff;
}
.millie-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 2px solid #f5a623; flex: 0 0 40px; }
.millie-head-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.millie-head-text strong { font-size: 16px; font-weight: 800; }
.millie-head-text span { font-size: 12px; color: #cbd5e1; display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.millie-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25); display: inline-block; }
.millie-icon-btn {
  width: 36px; height: 36px; flex: 0 0 36px;
  display: inline-flex; align-items: center; justify-content: center;
  border: none; border-radius: 10px; background: transparent; color: inherit; cursor: pointer;
}
.millie-head .millie-icon-btn:hover { background: rgba(255, 255, 255, 0.12); }

.millie-msgs {
  flex: 1;
  overflow-y: auto;
  padding: 16px 14px 8px;
  background: #f6f7fb;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}
.millie-row { display: flex; flex-direction: column; max-width: 88%; }
.millie-row--bot { align-self: flex-start; }
.millie-row--user { align-self: flex-end; align-items: flex-end; }
.millie .ai-msg {
  max-width: 100%;
  padding: 10px 13px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
  box-shadow: none;
  word-wrap: break-word;
}
.millie .ai-msg-bot { background: #ffffff; color: #1e293b; border: 1px solid #eceef2; border-bottom-left-radius: 6px; }
.millie .ai-msg-user { background: #0f172a; color: #ffffff; border: none; border-bottom-right-radius: 6px; }
.millie-time { font-size: 10.5px; color: #94a3b8; margin: 3px 6px 8px; }
.millie-list { margin: 6px 0 0; padding-left: 4px; list-style: none; display: flex; flex-direction: column; gap: 4px; }

.millie-typing { display: inline-flex; gap: 4px; padding: 13px 14px !important; }
.millie-typing span { width: 7px; height: 7px; border-radius: 50%; background: #94a3b8; animation: millieDot 1s infinite ease-in-out; }
.millie-typing span:nth-child(2) { animation-delay: 0.15s; }
.millie-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes millieDot { 0%, 80%, 100% { opacity: 0.35; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }

/* Listing mini-cards */
.millie-cards { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.millie-card {
  display: flex; gap: 10px; align-items: center;
  padding: 8px; border-radius: 12px; border: 1px solid #eceef2; background: #ffffff;
  text-decoration: none; color: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.millie-card:hover { border-color: #f5a623; box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08); }
.millie-card-img {
  position: relative; width: 64px; height: 56px; flex: 0 0 64px;
  border-radius: 9px; overflow: hidden; background: #fff7ed;
  display: flex; align-items: center; justify-content: center;
}
.millie-card-img b { font-size: 22px; color: #f5a623; }
.millie-card-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.millie-card-body { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
.millie-card-body strong { font-size: 13px; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.millie-card-body small { font-size: 11.5px; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.millie-card-body em { font-style: normal; font-size: 14px; font-weight: 800; color: #0f172a; }
.millie-card-body em span { font-size: 11px; font-weight: 600; color: #64748b; }

/* Action buttons inside answers */
.millie-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.millie-btn {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 7px 12px; border-radius: 999px;
  font-size: 12.5px; font-weight: 700; font-family: inherit;
  text-decoration: none; cursor: pointer;
  background: #ffffff; color: #0f172a; border: 1px solid #e2e8f0;
}
.millie-btn:hover { border-color: #cbd5e1; background: #f8fafc; }
.millie-btn--primary { background: #f5a623; border-color: #f5a623; color: #0f172a; }
.millie-btn--primary:hover { background: #e8971a; border-color: #e8971a; }

/* Quick replies */
.millie-chips {
  display: flex; gap: 6px; padding: 8px 12px; overflow-x: auto;
  background: #f6f7fb; scrollbar-width: none;
}
.millie-chips:empty { display: none; }
.millie-chips::-webkit-scrollbar { display: none; }
.millie-chip {
  flex: 0 0 auto;
  padding: 7px 12px; border-radius: 999px;
  border: 1px solid #fcd9a0; background: #fffaf2; color: #92400e;
  font-size: 12.5px; font-weight: 700; font-family: inherit; cursor: pointer; white-space: nowrap;
}
.millie-chip:hover { background: #fff3dd; border-color: #f5a623; }

/* Composer */
.millie-input {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 10px 12px; border-top: 1px solid #eef0f3; background: #ffffff;
}
.millie-input input {
  flex: 1; min-width: 0; height: 42px; padding: 0 14px;
  border: 1px solid #e2e8f0; border-radius: 999px; background: #f8fafc;
  font-size: 14px; font-family: inherit; outline: none;
}
.millie-input input:focus { border-color: #f5a623; background: #ffffff; box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.15); }
.millie-send {
  width: 42px; height: 42px; flex: 0 0 42px; border-radius: 50%; border: none;
  background: #0f172a; color: #ffffff; display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.millie-send:hover { background: #1e293b; }
.millie-mic { color: #64748b; }
.millie-mic:hover { background: #f1f5f9; color: #0f172a; }
.millie-mic.is-listening { background: #fee2e2; color: #dc2626; animation: milliePulse 1.2s infinite; }
@keyframes milliePulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.35); } 50% { box-shadow: 0 0 0 6px rgba(220, 38, 38, 0); } }

/* Bubble extras: unread dot + one-time nudge */
.millie-unread {
  position: absolute; top: 2px; right: 2px; width: 13px; height: 13px; border-radius: 50%;
  background: #ef4444; border: 2px solid #ffffff;
}
.millie-unread[hidden] { display: none; }
.millie-nudge {
  position: fixed; right: 96px; bottom: 104px; z-index: 5001;
  max-width: 250px; padding: 12px 30px 12px 14px;
  background: #ffffff; border: 1px solid #eceef2; border-radius: 14px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.18);
  display: flex; flex-direction: column; gap: 2px; cursor: pointer;
  font-size: 13px; color: #475569; animation: millieIn 0.2s ease-out;
}
.millie-nudge strong { color: #0f172a; font-size: 14px; }
.millie-nudge[hidden] { display: none; }
.millie-nudge-close {
  position: absolute; top: 6px; right: 8px; border: none; background: none;
  font-size: 16px; color: #94a3b8; cursor: pointer; line-height: 1;
}
body:not(:has(.rh-wa-float)) .millie-nudge { bottom: 36px; }

/* Size toggle icon: expand when compact, collapse when full */
.millie-icon-btn .ico-collapse { display: none; }
.millie--full .millie-icon-btn .ico-expand { display: none; }
.millie--full .millie-icon-btn .ico-collapse { display: block; }
.millie-handle { display: none; }
.millie-backdrop { display: none; }

/* Desktop "full screen": a big panel instead of the small one */
@media (min-width: 601px) {
  .ai-chat-window.millie.millie--full {
    width: min(560px, calc(100vw - 48px));
    height: calc(100vh - 120px);
    bottom: 24px;
    right: 24px;
    z-index: 10050;
  }
  body.millie-open.millie-full .ai-chat-bubble { display: none !important; }
}

/* Phones: compact bottom sheet (default) or full screen */
@media (max-width: 600px) {
  .ai-chat-window.millie {
    top: auto !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 64vh !important;
    min-height: 420px;
    max-height: 88vh;
    border-radius: 22px 22px 0 0;
    border: none;
    z-index: 10050;
    transition: height 0.22s ease, border-radius 0.22s ease, transform 0.22s ease;
  }
  .ai-chat-window.millie.millie--full {
    top: 0 !important;
    height: 100% !important;
    max-height: none;
    border-radius: 0;
  }
  .ai-chat-window.millie.active { animation: millieUp 0.22s ease-out; }
  @keyframes millieUp { from { transform: translateY(40px); opacity: 0.6; } to { transform: none; opacity: 1; } }

  /* Grab handle on the compact sheet (drag down to minimise) */
  .millie-handle {
    display: flex;
    justify-content: center;
    padding: 8px 0 0;
    background: #0f172a;
    border-radius: 22px 22px 0 0;
    touch-action: none;
  }
  .millie-handle span { width: 40px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.35); }
  .millie--full .millie-handle { display: none; }
  .millie-head { touch-action: pan-x; }
  .millie--full .millie-head { padding-top: max(14px, env(safe-area-inset-top)); }
  .millie-input { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
  .millie-input input { font-size: 16px; }

  /* Dim the page behind the compact sheet; tap it to minimise */
  .millie-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.35);
    z-index: 10040;
    opacity: 0;
    transition: opacity 0.2s ease;
  }
  .millie-backdrop.active { display: block; opacity: 1; }
  body.millie-open.millie-full { overflow: hidden; }
  body.millie-open .ai-chat-bubble,
  body.millie-open .rh-wa-float,
  body.millie-open .back-to-top { display: none !important; }
  .millie-nudge { right: 74px; bottom: 80px; max-width: 220px; }
  body:not(:has(.rh-wa-float)) .millie-nudge { bottom: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .ai-chat-window.millie.active, .millie-nudge { animation: none; }
  .millie-typing span, .millie-mic.is-listening { animation: none; }
}
