:root {
  --brand: #00ae66;
  --brand-dark: #009258;
  --brand-soft: #e8f8f0;
  --price: #fa5741;
  --text: #222;
  --text-2: #394043;
  --muted: #8a8f99;
  --line: #e6e6e6;
  --bg: #f5f5f6;
  --white: #fff;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  --radius: 8px;
}

* { box-sizing: border-box; }
html {
  margin: 0;
  padding: 0;
  scrollbar-gutter: stable;
  overflow-y: scroll;
}
body {
  margin: 0;
  padding: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.5;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; }
.wrap { width: 1152px; margin: 0 auto; }
.muted { color: var(--muted); }
.hidden { display: none !important; }

/* ===== header ===== */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 40;
}
.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 36px;
  font-size: 12px;
  color: var(--muted);
}
.header-top .header-links a {
  margin-left: 16px;
}
.header-top .header-links a:hover { color: var(--brand); }
.city-picker {
  position: relative;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}
.city-switch {
  border: 0;
  background: none;
  color: var(--text-2);
  cursor: pointer;
  padding: 0 6px 0 0;
}
.city-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 50;
  width: 280px;
  max-height: 360px;
  overflow: auto;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 6px;
  padding: 8px;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}
.city-picker.open .city-menu { display: grid; }
.city-menu button {
  border: 0;
  background: none;
  text-align: left;
  padding: 6px 8px;
  cursor: pointer;
  color: var(--text-2);
  border-radius: 4px;
  font-size: 12px;
}
.city-menu button:hover,
.city-menu button.active {
  background: var(--brand-soft);
  color: var(--brand);
}
.header-main {
  display: flex;
  align-items: center;
  height: 72px;
  gap: 32px;
}
.logo {
  flex: none;
  display: flex;
  align-items: center;
  line-height: 0;
}
.logo img {
  height: 56px;
  width: auto;
  border-radius: 8px;
}
.nav { display: flex; gap: 28px; font-size: 16px; }
.nav a { color: var(--text-2); padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a.active { color: var(--brand); border-color: var(--brand); }
.header-search {
  margin-left: auto;
  display: flex;
  width: 360px;
  height: 40px;
  border: 1px solid var(--brand);
  border-radius: 4px;
  overflow: hidden;
}
.header-search input {
  flex: 1;
  border: 0;
  padding: 0 12px;
  outline: none;
}
.header-search button {
  width: 72px;
  border: 0;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
}
.header-search button:hover { background: var(--brand-dark); }

/* ===== hero ===== */
.hero {
  height: 420px;
  background:
    linear-gradient(180deg, rgba(0,0,0,.25), rgba(0,0,0,.35)),
    url("https://images.unsplash.com/photo-1560448204-e02f11c3d0e2?auto=format&fit=crop&w=1600&q=80") center/cover no-repeat;
  display: flex;
  align-items: center;
}
.hero-inner { color: #fff; width: 100%; }
.hero h1 { font-size: 36px; font-weight: 700; margin: 0 0 24px; text-shadow: 0 2px 8px rgba(0,0,0,.25); }
.search-box {
  background: #fff;
  border-radius: 6px;
  padding: 18px 20px 20px;
  width: 760px;
  color: var(--text);
}
.search-tabs { display: flex; gap: 28px; margin-bottom: 14px; }
.search-tabs button {
  border: 0;
  background: none;
  font-size: 16px;
  font-weight: 600;
  padding: 0 0 8px;
  cursor: pointer;
  color: var(--text-2);
  border-bottom: 2px solid transparent;
}
.search-tabs button.active { color: var(--brand); border-color: var(--brand); }
.search-row { display: flex; height: 48px; }
.search-row input {
  flex: 1;
  border: 1px solid #ddd;
  border-right: 0;
  border-radius: 4px 0 0 4px;
  padding: 0 16px;
  outline: none;
}
.search-row button {
  width: 120px;
  border: 0;
  background: var(--brand);
  color: #fff;
  border-radius: 0 4px 4px 0;
  cursor: pointer;
  font-size: 16px;
}
.search-row button:hover { background: var(--brand-dark); }
.hot-words { margin-top: 10px; font-size: 13px; color: var(--muted); }
.hot-words a { margin-right: 14px; }
.hot-words a:hover { color: var(--brand); }

/* ===== sections ===== */
.section { padding: 40px 0; }
.section.gray { background: var(--bg); }
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}
.section-head h2 { margin: 0; font-size: 24px; }
.section-head a { color: var(--muted); font-size: 14px; }
.section-head a:hover { color: var(--brand); }

.entry-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
.entry-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 20px;
  transition: box-shadow .2s, transform .2s;
}
.entry-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.entry-card strong { display: block; font-size: 18px; margin-bottom: 6px; }
.entry-card p { margin: 0; color: var(--muted); font-size: 13px; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.house-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  transition: box-shadow .2s, transform .2s;
}
.house-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.house-card .cover {
  height: 160px;
  background: #ddd center/cover no-repeat;
  position: relative;
}
.house-card .cover .tag {
  position: absolute;
  left: 8px;
  top: 8px;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 12px;
  padding: 2px 6px;
  border-radius: 2px;
}
.house-card .body { padding: 12px 12px 14px; }
.house-card .title {
  font-size: 15px;
  font-weight: 600;
  height: 44px;
  overflow: hidden;
}
.house-card .meta { color: var(--muted); font-size: 12px; margin: 6px 0; }
.house-card .price { color: var(--price); font-weight: 700; font-size: 20px; }
.house-card .price em { font-style: normal; font-size: 13px; }
.house-card .unit { color: var(--muted); font-size: 12px; margin-left: 8px; font-weight: 400; }
.house-card .tags { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  font-size: 12px;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 1px 6px;
  border-radius: 2px;
}
.chip.orange { color: #d48806; background: #fff7e6; }
.chip.gray { color: #666; background: #f3f3f3; }

.agent-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.agent-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  gap: 12px;
}
.agent-card img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
}
.agent-card h3 { margin: 0 0 4px; font-size: 16px; }
.agent-card p { margin: 0; font-size: 12px; color: var(--muted); }

/* ===== list / filter ===== */
.page-banner {
  background: var(--bg);
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.crumb { font-size: 13px; color: var(--muted); }
.crumb a:hover { color: var(--brand); }
.page-title { margin: 8px 0 0; font-size: 22px; }
.filter-box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 20px 4px;
  margin: 20px 0;
}
.filter-row {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 13px;
}
.filter-row:last-child { border-bottom: 0; }
.filter-row .label { width: 56px; color: var(--muted); flex: none; padding-top: 4px; }
.filter-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-opts button {
  border: 0;
  background: none;
  color: var(--text-2);
  padding: 4px 10px;
  cursor: pointer;
  border-radius: 3px;
}
.filter-opts button:hover,
.filter-opts button.active {
  color: var(--brand);
  background: var(--brand-soft);
}
.list-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 14px;
}
.sort a, .sort button {
  border: 0;
  background: none;
  color: var(--muted);
  margin-left: 16px;
  cursor: pointer;
}
.sort .active { color: var(--brand); font-weight: 600; }
.list-layout { display: flex; flex-direction: column; gap: 16px; padding-bottom: 40px; }
.list-item {
  display: flex;
  gap: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}
.list-item:hover { box-shadow: var(--shadow); }
.list-item .cover {
  width: 260px;
  height: 180px;
  background: #ddd center/cover no-repeat;
  border-radius: 4px;
  flex: none;
  position: relative;
}
.list-item .info { flex: 1; min-width: 0; }
.list-item h3 { margin: 0 0 8px; font-size: 20px; }
.list-item .desc { color: var(--text-2); margin-bottom: 8px; }
.list-item .comm { color: var(--muted); font-size: 13px; }
.list-item .side {
  width: 180px;
  text-align: right;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.empty {
  text-align: center;
  padding: 60px 0;
  color: var(--muted);
}

/* ===== detail ===== */
.gallery {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 10px;
  margin: 20px 0;
}
.gallery-main {
  height: 420px;
  background: #111 center/cover no-repeat;
  border-radius: 6px;
}
.gallery-thumbs { display: flex; flex-direction: column; gap: 8px; }
.gallery-thumbs button {
  height: 98px;
  border: 2px solid transparent;
  border-radius: 4px;
  background: #ccc center/cover no-repeat;
  cursor: pointer;
  padding: 0;
}
.gallery-thumbs button.active { border-color: var(--brand); }
.detail-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  padding-bottom: 48px;
}
.price-block .total { color: var(--price); font-size: 36px; font-weight: 800; }
.price-block .unit { color: var(--muted); margin-left: 10px; }
.spec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px 20px;
  margin: 20px 0;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.spec-grid div { font-size: 14px; color: var(--muted); }
.spec-grid strong { display: block; color: var(--text); font-size: 16px; margin-top: 4px; }
.agent-box {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  position: sticky;
  top: 96px;
}
.agent-box .row { display: flex; gap: 12px; margin-bottom: 16px; }
.agent-box img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  border-radius: 4px;
  border: 0;
  cursor: pointer;
  width: 100%;
  font-size: 15px;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-ghost {
  background: #fff;
  border: 1px solid var(--brand);
  color: var(--brand);
  margin-top: 10px;
}
.btn-ghost.active { background: var(--brand-soft); }
.form-field { margin-bottom: 12px; }
.form-field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.form-field input, .form-field select, .form-field textarea {
  width: 100%;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 9px 10px;
  outline: none;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  border-color: var(--brand);
}
.toast {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,.78);
  color: #fff;
  padding: 10px 18px;
  border-radius: 4px;
  z-index: 80;
}

/* ===== sell form ===== */
.form-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 32px 36px;
  width: 720px;
  margin: 24px auto 48px;
}
.form-card h2 { margin: 0 0 20px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.form-card .full { grid-column: 1 / -1; }

/* ===== service / help / feedback ===== */
.article-page { padding: 24px 0 56px; }
.article-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}
.article-nav a {
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  font-size: 13px;
  color: var(--text-2);
}
.article-nav a.active,
.article-nav a:hover {
  border-color: var(--brand);
  color: var(--brand);
  background: var(--brand-soft);
}
.article-lead {
  font-size: 16px;
  color: var(--text-2);
  margin: 0 0 24px;
  line-height: 1.7;
}
.step-list {
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.step-list li {
  position: relative;
  padding: 0 0 20px 56px;
  counter-increment: step;
}
.step-list li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.step-list strong { display: block; margin-bottom: 4px; }
.step-list p { margin: 0; color: var(--muted); }
.info-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}
.info-cards div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 16px;
  background: var(--bg);
}
.info-cards h3 { margin: 0 0 8px; font-size: 15px; }
.info-cards p { margin: 0; color: var(--muted); font-size: 13px; }
.article-cta { color: var(--text-2); }
.article-cta a { color: var(--brand); }
.article-form { width: auto; max-width: 720px; margin: 0; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 16px 36px 16px 0;
  cursor: pointer;
  font-size: 16px;
  position: relative;
}
.faq-q::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 16px;
  color: var(--brand);
  font-size: 20px;
}
.faq-item.open .faq-q::after { content: "–"; }
.faq-a {
  display: none;
  padding: 0 0 16px;
  color: var(--text-2);
  line-height: 1.7;
}
.faq-item.open .faq-a { display: block; }
.faq-a a { color: var(--brand); }

/* ===== footer ===== */
.site-footer {
  background: #222;
  color: #bbb;
  padding: 36px 0 20px;
  font-size: 13px;
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}
.site-footer h4 { color: #fff; margin: 0 0 10px; font-size: 14px; }
.footer-logo { display: inline-block; margin-bottom: 12px; }
.footer-logo img { height: 72px; width: auto; border-radius: 8px; }
.site-footer a { color: #bbb; display: block; margin: 6px 0; }
.site-footer a:hover { color: #fff; }
.copyright { border-top: 1px solid #333; padding-top: 14px; color: #777; }

#more-list.card-grid { grid-template-columns: repeat(2, 1fr); }

@media (max-width: 1180px) {
  .wrap { width: auto; margin: 0 20px; }
  .card-grid, .entry-grid, .agent-grid { grid-template-columns: repeat(2, 1fr); }
  .header-search { width: 240px; }
  .search-box { width: 100%; }
  .detail-layout, .gallery { grid-template-columns: 1fr; }
  .gallery-thumbs { flex-direction: row; }
  .gallery-thumbs button { width: 96px; height: 72px; }
  .info-cards { grid-template-columns: 1fr; }
}