
:root {
  /* Light colour palette for a brighter theme */
  --bg: #f9fafb;
  --bg-elevated: #ffffff;
  --card: #ffffff;
  --border: #e5e7eb;
  --accent: #007acc;
  --text: #1f2937;
  --text-muted: #6b7280;
  --radius: 0.9rem;
}

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

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  /* Remove dark radial gradient and use the base background colour. */
  background: var(--bg);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* HEADER */

.site-header {
  border-bottom: 1px solid rgba(229, 231, 235, 0.8);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 20;
  /* Light header gradient to blend with pale backgrounds */
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.85));
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  /* allow wrapping so the search bar can stack on a new line when needed */
  flex-wrap: wrap;
}

.logo a {
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 1.1rem;
}

.logo span {
  color: var(--accent);
}

.main-nav {
  display: flex;
  gap: 1rem;
  align-items: center;
  font-size: 0.9rem;
}

.main-nav a {
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  color: var(--text-muted);
}

.main-nav a:hover {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text);
}

/* Header search bar */
.header-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  /* Place search bar in the same row as the navigation. Allow it to push to
     the right by using margin-left:auto. Remove full-width basis so it
     doesn't wrap onto its own row. */
  flex-basis: auto;
  margin: 0;
  margin-left: auto;
}

.header-search input[type="text"] {
  /* make the search input larger and more prominent */
  padding: 0.7rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(209, 213, 219, 0.7);
  background: var(--card);
  width: 100%;
  max-width: 500px;
  font-size: 1rem;
}

/* BUTTONS */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  background: var(--accent);
  color: #ffffff;
}

.btn-outline {
  background: transparent;
  border-color: rgba(209, 213, 219, 0.7);
  color: var(--accent);
}

.btn:hover {
  filter: brightness(1.1);
}

.btn-full {
  width: 100%;
}

/* Back link styling */
.back-link {
  display: inline-block;
  margin-bottom: 1rem;
  font-size: 0.85rem;
  color: var(--accent);
}
.back-link:hover {
  text-decoration: underline;
}


/* LAYOUT */

.page-main {
  padding-bottom: 3.5rem;
}

.hero-section {
  padding: 3rem 0 2.5rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.5fr);
  gap: 2.5rem;
  align-items: center;
}

/* HERO */

.hero-copy h1 {
  font-size: 2.5rem;
  line-height: 1.05;
  margin-bottom: 0.75rem;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.98rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0 1rem;
}

.hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.hero-highlights span {
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(240, 249, 255, 0.95);
}

.card {
  border-radius: 1.1rem;
  border: 1px solid rgba(229, 231, 235, 0.8);
  /* Lighten cards by applying subtle blue overlays on white */
  background:
    radial-gradient(circle at top left, rgba(0, 122, 204, 0.05), transparent 55%),
    radial-gradient(circle at bottom right, rgba(0, 122, 204, 0.03), transparent 55%),
    #ffffff;
  padding: 1.4rem 1.3rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.05);
}

.hero-panel h2 {
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

.hero-search {
  display: flex;
  gap: 0.6rem;
  margin: 1rem 0 1.25rem;
}

.hero-search input {
  flex: 1;
  padding: 0.65rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(209, 213, 219, 0.7);
  background: var(--card);
  color: var(--text);
  font-size: 0.9rem;
}

.hero-stats {
  display: grid;
  gap: 0.85rem;
  font-size: 0.8rem;
  margin-top: 0.5rem;
}

.stat-label {
  color: var(--text-muted);
}

.stat-value {
  font-weight: 500;
}

/* FEATURES */

.features-section {
  padding: 2.5rem 0 1rem;
}

.section-header {
  margin-bottom: 1.6rem;
}

.section-header h2 {
  font-size: 1.4rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.feature-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}

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

/* AUTH */

.auth-section {
  padding: 3rem 0;
}

.auth-container {
  max-width: 420px;
  margin: 0 auto;
}

.auth-card h1 {
  margin-top: 0;
  margin-bottom: 0.4rem;
}

.auth-card .subtitle {
  margin-bottom: 1.4rem;
}

/* FORMS */

.form-group {
  margin-bottom: 0.9rem;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  margin-bottom: 0.25rem;
  color: var(--text-muted);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 0.55rem 0.7rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(209, 213, 219, 0.7);
  background: var(--card);
  color: var(--text);
  font-size: 0.9rem;
}

textarea {
  resize: vertical;
}

.auth-switch {
  font-size: 0.85rem;
  margin-top: 0.7rem;
  color: var(--text-muted);
}

.auth-switch a {
  color: var(--accent);
}

/* ALERTS */

.alert {
  border-radius: 0.75rem;
  padding: 0.7rem 0.9rem;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}

.alert-error {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.5);
}

.alert-success {
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.5);
}

/* LISTINGS */

.listings-section {
  padding: 2.5rem 0;
}

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.search-form {
  display: flex;
  gap: 0.6rem;
}

.search-form input {
  padding: 0.55rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(209, 213, 219, 0.7);
  background: var(--card);
  color: var(--text);
  font-size: 0.9rem;
}

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

/* Generic info grid used on the property detail page */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.info-item {
  padding: 0.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.info-key {
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 0.2rem;
}

.info-value {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.listing-card {
  border-radius: 1rem;
  border: 1px solid rgba(229, 231, 235, 0.8);
  background: var(--card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.listing-thumb {
  height: 140px;
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.4), transparent 55%),
              radial-gradient(circle at bottom, rgba(59, 130, 246, 0.3), transparent 55%);
  position: relative;
}

.listing-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  background: var(--bg-elevated);
  border: 1px solid rgba(209, 213, 219, 0.8);
}

.listing-body {
  padding: 0.9rem 0.95rem 0.85rem;
}

.listing-title {
  font-size: 0.98rem;
  margin: 0 0 0.2rem;
}

.listing-address {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.listing-meta {
  display: flex;
  gap: 0.7rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.listing-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  margin-top: 0.2rem;
}

.listing-price {
  font-weight: 600;
}

/* DETAIL */

.listing-detail-section {
  padding: 2.5rem 0;
}

.detail-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.detail-address {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.detail-price-block {
  text-align: right;
}

.detail-price {
  font-size: 1.4rem;
  margin: 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(0, 1.1fr);
  gap: 1.1rem;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.key-facts {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.86rem;
}

.key-facts li {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.key-facts span {
  color: var(--text-muted);
}

/* DASHBOARD */

.dashboard-section {
  padding: 2.5rem 0;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin-bottom: 1.5rem;
}

.stat-card .label {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.stat-card .value {
  font-size: 1.2rem;
  margin-top: 0.25rem;
}

.simple-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.simple-list li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(30, 64, 175, 0.3);
}

.item-title {
  font-size: 0.92rem;
}

.item-meta {
  text-align: right;
  font-size: 0.82rem;
}

/* BADGES */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.6);
}

.status-active {
  background: rgba(22, 163, 74, 0.12);
  border-color: rgba(22, 163, 74, 0.6);
}

.status-pending {
  background: rgba(234, 179, 8, 0.12);
  border-color: rgba(234, 179, 8, 0.7);
}

.status-under_contract {
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.7);
}

.status-sold {
  background: rgba(148, 163, 184, 0.18);
}

/* FORMS LAYOUT */

.form-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1.2fr);
  gap: 1rem;
}

.form-section h2 {
  margin-top: 0;
  margin-bottom: 0.6rem;
}

.help {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* FOOTER */

.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding: 1.3rem 0 1.5rem;
  margin-top: 2.5rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* UTILITIES */

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

/* RESPONSIVE */

@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-panel {
    order: -1;
  }

  .feature-grid,
  .form-grid,
  .detail-grid,
  .dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .header-inner,
  .hero-actions,
  .footer-inner,
  .page-header,
  .dashboard-header,
  .detail-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .main-nav {
    flex-wrap: wrap;
  }
}

/* Additional Info Grid for property detail */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.7rem;
    margin-top: 0.4rem;
}
.info-item {
    border-radius: 0.8rem;
    padding: 0.6rem 0.7rem;
    border: 1px solid rgba(148,163,184,0.35);
    background:
        radial-gradient(circle at top left, rgba(56,189,248,0.10), transparent 55%),
        rgba(15,23,42,0.9);
    font-size: 0.82rem;
}
.info-key {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 0.15rem;
}
.info-value {
    font-size: 0.86rem;
    color: var(--text);
    word-break: break-word;
}
.info-value-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.1rem 0.5rem;
    border-radius: 999px;
    font-size: 0.75rem;
    border: 1px solid rgba(148,163,184,0.5);
}
.info-value-badge.yes {
    background: rgba(34,197,94,0.18);
    border-color: rgba(34,197,94,0.6);
}
.info-value-badge.no {
    background: rgba(239,68,68,0.18);
    border-color: rgba(239,68,68,0.6);
}
.info-value-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}
.info-chip {
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    font-size: 0.75rem;
    background: rgba(15,23,42,0.9);
    border: 1px solid rgba(148,163,184,0.4);
}

/*
 * The header-search styles below were duplicated in this file. The
 * original definitions made the search bar small and aligned to the
 * left, conflicting with the new design that centers the search bar
 * and makes it full-width for logged in users. To avoid conflicting
 * definitions, the older styles have been removed. All header search
 * appearance is now controlled near the top of this file where the
 * full-width, centered search bar styles live.
 */

/*
 * Listing page styles migrated from listing.php
 * These rules give the single-property listing pages a polished look with
 * cards, meta rows, sliders and responsive layouts. All selectors are
 * prefixed with `.listing-page` to scope them to the property details
 * pages only.
 */

/* Container and layout */
.listing-page {
    background: #f3f4f6;
    padding: 1rem 0 2rem;
}
.listing-page .listing-container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Block cards */
.listing-page .block-card {
    background: #ffffff;
    border-radius: 1rem;
    border: 1px solid #e5e7eb;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
    padding: 1.3rem 1.4rem;
    margin-bottom: 1rem;
}

.listing-page .section-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
}
.listing-page .section-subtitle {
    font-size: 0.84rem;
    color: #6b7280;
}

/* Tags & title */
.listing-page .tags-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}
.listing-page .chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    padding: 0.15rem 0.7rem;
    font-size: 0.72rem;
    font-weight: 500;
    text-transform: capitalize;
    background: #f9fafb;
}
.listing-page .listing-title {
    font-size: 1.9rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}
.listing-page .meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
    font-size: 0.9rem;
    color: #6b7280;
}
.listing-page .title-top-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

/* Hero slider */
.listing-page .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
    gap: 1.6rem;
    margin-bottom: 1.3rem;
}
.listing-page .photo-slider {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    border: 1px solid #e5e7eb;
    background: #ffffff;
}
.listing-page .photo-slider img {
    width: 100%;
    display: block;
    object-fit: cover;
}
.listing-page .thumb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.5rem;
    margin-top: 0.6rem;
}
.listing-page .thumb-grid img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
    cursor: pointer;
}

/* Price & rent sliders */
.listing-page .value-slider,
.listing-page .rent-slider {
    margin-top: 1rem;
}
.listing-page .slider-label {
    font-size: 0.78rem;
    color: #6b7280;
    margin-bottom: 0.15rem;
}
.listing-page .range-slider {
    position: relative;
    height: 3.5rem;
}
.listing-page .range-slider .range-line {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
}
.listing-page .range-slider .range-fill {
    position: absolute;
    top: 50%;
    height: 4px;
    background: #bfdbfe;
    border-radius: 2px;
    transform: translateY(-50%);
}
.listing-page .range-slider .range-marker {
    position: absolute;
    top: 50%;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #2563eb;
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 2px #2563eb;
    transform: translate(-50%, -50%);
}
.listing-page .range-slider .range-label {
    position: absolute;
    top: -1.2rem;
    font-size: 0.75rem;
    color: #1f2937;
    white-space: nowrap;
}
.listing-page .range-slider .range-median-line {
    position: absolute;
    top: 50%;
    width: 2px;
    height: 100%;
    background: #2563eb;
    transform: translateY(-50%);
}
.listing-page .range-slider .range-median-label {
    position: absolute;
    top: -1.2rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: #2563eb;
    white-space: nowrap;
}

/* Stat badges */
.listing-page .stats-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1rem;
}
.listing-page .stat-box {
    flex: 1 1 160px;
    padding: 0.8rem 1rem;
    background: #f9fafb;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    text-align: center;
}
.listing-page .stat-box .stat-title {
    font-size: 0.78rem;
    color: #6b7280;
    margin-bottom: 0.15rem;
}
.listing-page .stat-box .stat-value {
    font-size: 1.3rem;
    font-weight: 600;
}

/* Section grid */
.listing-page .section-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1.2rem;
}
.listing-page .info-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.86rem;
}
.listing-page .info-table th,
.listing-page .info-table td {
    padding: 0.4rem 0.6rem;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}
.listing-page .info-table th {
    font-weight: 600;
    color: #374151;
    background: #f9fafb;
}
.listing-page .info-table td {
    color: #374151;
}

/* Key value grid used by property-details fallback */
.listing-page .info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.6rem;
    margin-top: 1rem;
}
.listing-page .info-item {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 0.6rem 0.8rem;
}
.listing-page .info-item .info-key {
    font-size: 0.78rem;
    color: #6b7280;
    margin-bottom: 0.15rem;
}
.listing-page .info-item .info-value {
    font-size: 0.88rem;
    color: #1f2937;
    word-break: break-word;
}

/* Responsive tweaks */
@media (max-width: 768px) {
    .listing-page .hero-grid {
        grid-template-columns: 1fr;
    }
    .listing-page .stats-grid {
        flex-direction: column;
    }
}

/*
 * The following styles were migrated from listing.php.
 * They style the property detail pages (listing-page) including the photo grid,
 * modal, main grid, stats tiles, detail tables, sliders, map block and responsive tweaks.
 * Keeping these definitions in the global CSS ensures that the listing.php layout
 * is controlled centrally.
 */

.listing-page .photos-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: repeat(2, 170px);
    gap: 0.6rem;
}
.listing-page .photo-main,
.listing-page .photo-thumb {
    border-radius: 0.75rem;
    overflow: hidden;
    background: #e5e7eb;
    border: 1px solid #d1d5db;
}
.listing-page .photo-main {
    grid-column: span 2;
    grid-row: span 2;
}
.listing-page .photo-main img,
.listing-page .photo-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.listing-page .photo-thumb {
    position: relative;
}
.listing-page .photo-thumb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.45), transparent);
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 0.45rem;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
}
.listing-page .photos-footer {
    margin-top: 0.75rem;
    text-align: right;
}

/* Photos modal */
.listing-page .photos-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.listing-page .photos-modal {
    background: #ffffff;
    border-radius: 1rem;
    max-width: 960px;
    max-height: 80vh;
    width: 100%;
    padding: 1rem;
    overflow: auto;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.35);
}
.listing-page .photos-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}
.listing-page .photos-modal-title {
    font-size: 1rem;
    font-weight: 600;
}
.listing-page .photos-modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.6rem;
}
.listing-page .photos-modal-grid img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
}

/* Main grid for details and side panel */
.listing-page .main-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr);
    gap: 1.5rem;
    margin-top: 0.5rem;
}

/* Statistics row styling */
.listing-page .stat-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 0.6rem;
}
.listing-page .stat-tile {
    border-radius: 0.7rem;
    border: 1px solid #e5e7eb;
    padding: 0.6rem 0.75rem;
    background: #f9fafb;
}
.listing-page .stat-label {
    font-size: 0.78rem;
    color: #6b7280;
    margin-bottom: 0.1rem;
}
.listing-page .stat-value {
    font-size: 0.98rem;
    font-weight: 600;
}
.listing-page .stat-icon {
    margin-left: 0.25rem;
    font-size: 0.75rem;
}
.listing-page .stat-icon.up {
    color: #16a34a;
}
.listing-page .stat-icon.down {
    color: #dc2626;
}

/* Detail table overrides */
.listing-page .detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    margin-top: 0.4rem;
}
.listing-page .detail-table th,
.listing-page .detail-table td {
    padding: 0.38rem 0.25rem;
    text-align: left;
    vertical-align: top;
}
.listing-page .detail-table th {
    width: 40%;
    color: #6b7280;
    font-weight: 500;
}

/* Buttons scoped to listing page */
.listing-page .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 0.6rem 1.2rem;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: transform 0.08s ease, box-shadow 0.12s ease, background 0.12s ease;
}
.listing-page .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.18);
}
.listing-page .btn:active {
    transform: translateY(0);
    box-shadow: none;
}
.listing-page .btn-full { width: 100%; }
.listing-page .btn-primary {
    background: linear-gradient(135deg, #58a4b0, #111827);
    color: #ffffff;
}
.listing-page .btn-secondary {
    background: #ffffff;
    color: #111827;
    border: 1px solid #e5e7eb;
}

/* Snapshot / sliders sections */
.listing-page .pill-label {
    display: inline-block;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
    background: #e5f3f6;
    color: #0f172a;
    font-size: 0.78rem;
    font-weight: 600;
    margin-bottom: 0.6rem;
}
.listing-page .value-block {
    margin-bottom: 0.85rem;
}
.listing-page .value-main {
    font-size: 1.1rem;
    font-weight: 700;
}
.listing-page .value-range {
    font-size: 0.8rem;
    color: #6b7280;
    margin-top: 0.1rem;
}
.listing-page .slider-row {
    margin-top: 0.45rem;
}
.listing-page input[type="range"] {
    width: 100%;
}

/* Input row for value and rent and chips */
.listing-page .value-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
}
.listing-page .value-header-controls {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}
.listing-page .value-input {
    width: 120px;
    padding: 0.25rem 0.4rem;
    font-size: 0.8rem;
    border-radius: 999px;
    border: 1px solid #d1d5db;
    text-align: right;
    background: #ffffff;
    font-weight: 700;
}
.listing-page .value-input-wrapper {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    font-weight: 700;
}
.listing-page .value-input-wrapper span {
    font-size: 0.8rem;
}
.listing-page .btn-chip {
    padding: 0.2rem 0.6rem;
    font-size: 0.75rem;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    color: #111827;
    cursor: pointer;
}
.listing-page .btn-chip:hover {
    background: #e5e7eb;
}

/* Data table with bar graph cells */
.listing-page .data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.84rem;
    margin-top: 0.4rem;
}
.listing-page .data-table th,
.listing-page .data-table td {
    padding: 0.4rem 0.35rem;
    border-bottom: 1px solid #e5e7eb;
    text-align: left;
}
.listing-page .data-table thead {
    background: #f3f4f6;
}
.listing-page .data-table th {
    font-weight: 600;
    color: #6b7280;
    font-size: 0.78rem;
}
.listing-page .badge-year {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    border: 1px solid #d1d5db;
    font-size: 0.78rem;
}
.listing-page .bar-cell {
    position: relative;
    height: 0.6rem;
    border-radius: 999px;
    background: #e5e7eb;
    overflow: hidden;
}
.listing-page .bar-fill {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, #3b82f6, #10b981);
}
.listing-page .bar-label {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 0.15rem;
}

/* Map block */
.listing-page .map-iframe {
    width: 100%;
    border: none;
    border-radius: 0.75rem;
    height: 260px;
}

/* Features grid */
.listing-page .features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.6rem;
    margin-top: 0.4rem;
}
.listing-page .feature-item {
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    padding: 0.55rem 0.7rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}
.listing-page .feature-header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.listing-page .feature-icon {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #e5f3f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}
.listing-page .feature-label {
    font-size: 0.8rem;
    color: #6b7280;
    font-weight: 500;
}
.listing-page .feature-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: #111827;
}

/* Responsive tweaks for listing page */
@media (max-width: 900px) {
    .listing-page .main-grid {
        grid-template-columns: 1fr;
    }
    .listing-page .photos-grid {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: repeat(2, 160px);
    }
    .listing-page .photo-main {
        grid-column: span 2;
        grid-row: span 2;
    }
    .listing-page .title-top-row {
        flex-direction: column;
        align-items: flex-start;
    }
    .listing-page .status-top-right {
        margin-top: 0.5rem;
    }
}

/* Additional prototype-specific classes */
.listed-by {
    margin-top: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    text-align: center;
}

