* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #1f6fff;
  --primary-dark: #0e4fd8;
  --text: #132238;
  --muted: #6d7b90;
  --line: #e7edf7;
  --bg: #f5f8fd;
  --card: #ffffff;
  --orange: #ee8b12;
  --shadow: 0 20px 50px rgba(16, 43, 95, 0.08);
  --radius: 24px;
  --container: 1180px;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
button { font-family: inherit; }

.container {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  background: rgba(255,255,255,.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(19,34,56,.08);
  position: sticky;
  top: 0;
  z-index: 30;
}

.topbar-wrap {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  font-size: 1.35rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand span { color: var(--primary); }
.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: .78rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px rgba(31,111,255,0.26);
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-weight: 600;
}

.icon-btn {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: white;
  border: 1px solid var(--line);
  box-shadow: 0 8px 18px rgba(16,43,95,.06);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: .95rem;
  margin-top: 24px;
  margin-bottom: 26px;
}

.breadcrumb a { color: var(--primary-dark); font-weight: 600; }

.page {
  padding: 24px 0 72px;
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(330px, .85fr);
  gap: 28px;
  align-items: start;
}

.section-card,
.sidebar-card {
  background: var(--card);
  border-radius: 26px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.property-head {
  margin-bottom: 18px;
}

.property-head h1 {
  font-size: clamp(2rem, 3vw, 3.5rem);
  line-height: 1.08;
  margin-bottom: 8px;
  font-weight: 800;
}

.location {
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  font-size: 1.05rem;
}

.gallery-card {
  padding: 0;
  overflow: hidden;
}

.hero-image-wrap {
  position: relative;
  aspect-ratio: 1.34 / .86;
  overflow: hidden;
  background: #edf3ff;
}

.hero-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-nav {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  pointer-events: none;
}

.gallery-btn {
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.92);
  box-shadow: 0 10px 24px rgba(8,28,80,.14);
  font-size: 1.5rem;
  cursor: pointer;
  pointer-events: auto;
}

.thumbs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 16px;
  background: #fff;
}

.thumb {
  border: 2px solid transparent;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1.2 / .8;
  transition: .2s ease;
}

.thumb.active {
  border-color: var(--primary);
  box-shadow: 0 10px 22px rgba(31,111,255,.14);
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.price-card {
  margin-top: 22px;
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
}

.price-card .label {
  color: var(--muted);
  margin-bottom: 8px;
  font-size: .98rem;
}

.price {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--orange);
  font-weight: 800;
  line-height: 1;
  margin-bottom: 10px;
}

.action-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.btn {
  border: none;
  cursor: pointer;
  border-radius: 16px;
  padding: 14px 20px;
  font-weight: 700;
  font-size: .98rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: .25s ease;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  box-shadow: 0 14px 28px rgba(31,111,255,.22);
}

.btn-primary:hover { transform: translateY(-2px); }

.btn-light {
  background: #f3f7ff;
  color: var(--text);
  border: 1px solid #dce7fa;
}

.spec-strip {
  margin-top: 22px;
  padding: 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.spec-item {
  background: #f8fbff;
  border: 1px solid #e7effd;
  border-radius: 18px;
  padding: 18px;
  text-align: center;
}

.spec-item .value {
  display: block;
  font-size: 1.3rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.spec-item .name {
  color: var(--muted);
  font-size: .95rem;
}

.content-card {
  margin-top: 22px;
  padding: 28px;
}

.content-card h2 {
  font-size: 2rem;
  line-height: 1.12;
  margin-bottom: 14px;
}

.content-card p {
  color: #44546d;
  margin-bottom: 12px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.feature-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8fbff;
  border: 1px solid #e6eefb;
  font-weight: 600;
  color: #35455e;
}

.feature-pill span {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: #ebf3ff;
}

.cta-banner {
  margin-top: 22px;
  padding: 40px 30px;
  text-align: center;
  color: white;
  background:
    linear-gradient(90deg, rgba(8,28,80,.88), rgba(15,79,209,.78)),
    url('https://images.unsplash.com/photo-1505693416388-ac5ce068fe85?auto=format&fit=crop&w=1600&q=80') center/cover no-repeat;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.cta-banner h3 {
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  line-height: 1.1;
  margin-bottom: 10px;
}

.cta-banner p {
  color: rgba(255,255,255,.88);
  max-width: 680px;
  margin: 0 auto 20px;
}

.recommend-card {
  margin-top: 28px;
  padding: 0;
  overflow: hidden;
}

.recommend-head {
  padding: 24px 24px 8px;
}

.recommend-head h2 {
  font-size: 2rem;
  line-height: 1.12;
}

.recommend-grid {
  padding: 0 24px 24px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.mini-card {
  overflow: hidden;
  background: #fff;
  border-radius: 22px;
  border: 1px solid var(--line);
  transition: .25s ease;
}

.mini-card:hover { transform: translateY(-4px); }

.mini-card img {
  width: 100%;
  aspect-ratio: 1.15 / .75;
  object-fit: cover;
}

.mini-body {
  padding: 16px;
}

.mini-body h4 {
  font-size: 1.2rem;
  line-height: 1.2;
  margin-bottom: 6px;
}

.mini-price {
  color: var(--orange);
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.mini-body p {
  color: var(--muted);
  font-size: .93rem;
}

.sidebar-stack {
  display: grid;
  gap: 22px;
  position: sticky;
  top: 100px;
}

.agent-card {
  padding: 24px;
}

.agent-card h3 {
  font-size: 2rem;
  line-height: 1.08;
  margin-bottom: 14px;
}

.agent-top {
  display: grid;
  grid-template-columns: 1fr 132px;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}

.agent-price {
  color: var(--orange);
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 10px;
}

.agent-top p {
  color: var(--muted);
  font-size: .97rem;
}

.agent-photo {
  width: 132px;
  height: 160px;
  border-radius: 22px;
  object-fit: cover;
  background: #eef3ff;
}

.contact-box {
  margin-top: 14px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #eff5ff, #f9fbff);
  border: 1px solid #dde8ff;
  border-radius: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  color: var(--primary-dark);
}

.sidebar-card .btn {
  width: 100%;
  margin-top: 16px;
}

.address-box {
  margin-top: 16px;
  padding: 16px;
  border-radius: 18px;
  background: #f8fbff;
  border: 1px solid #e6eefb;
  color: #43536c;
  font-weight: 500;
}

.map-card {
  overflow: hidden;
  padding: 0;
}

.map-card h4 {
  font-size: 1.7rem;
  padding: 24px 24px 12px;
}

.map-frame {
  position: relative;
  height: 280px;
  background:
    linear-gradient(rgba(255,255,255,.1), rgba(255,255,255,.1)),
    url('https://images.unsplash.com/photo-1524661135-423995f22d0b?auto=format&fit=crop&w=1400&q=80') center/cover no-repeat;
}

.map-pin {
  position: absolute;
  width: 28px;
  height: 28px;
  border-radius: 50% 50% 50% 0;
  background: #ff544f;
  transform: rotate(-45deg);
  left: 58%;
  top: 42%;
  box-shadow: 0 10px 18px rgba(255,84,79,.28);
}

.map-pin::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  background: white;
  border-radius: 50%;
  left: 9px;
  top: 9px;
}

.map-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 16px 20px 22px;
}

.map-tags span {
  padding: 10px 14px;
  background: #f5f8fd;
  border: 1px solid #e3ecfa;
  border-radius: 999px;
  color: #4b5b73;
  font-size: .92rem;
  font-weight: 600;
}

@media (max-width: 1100px) {
  .main-grid,
  .agent-top,
  .recommend-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .sidebar-stack {
    position: static;
  }

  .agent-photo {
    width: 100%;
    max-width: 220px;
    height: 250px;
  }
}

@media (max-width: 860px) {
  .spec-strip,
  .thumbs {
    grid-template-columns: repeat(2, 1fr);
  }

  .price-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .topbar-wrap {
    flex-direction: column;
    justify-content: center;
    padding: 14px 0;
  }

  .spec-strip,
  .feature-grid,
  .recommend-grid,
  .thumbs {
    grid-template-columns: 1fr;
  }

  .property-head h1 { font-size: 2.2rem; }
  .content-card,
  .price-card,
  .agent-card,
  .recommend-head,
  .recommend-grid { padding-left: 18px; padding-right: 18px; }
}
