/* ============================================================
   惠房甄选 v7 · 公共框架与房源组件（前缀 hf_）
   头部：白底单行吸顶（logo / 导航 / 热线 / 入驻按钮）
   页脚：深青色，顶部入驻横幅 + 五列 + 平台声明
   组件：房源卡（竖）、房源行（横，列表页）、页头、侧栏盒、正文
   ============================================================ */

body { background: var(--hf-bg); color: var(--hf-ink); }
.hf_wrap { max-width: var(--hf-wrap); margin: 0 auto; padding: 0 20px; }
.hf_main { min-height: 50vh; }

/* ---------- 头部 ---------- */
.hf_head { position: sticky; top: 0; z-index: 80; background: #fff; border-bottom: 1px solid var(--hf-line); transition: box-shadow .2s ease; }
.hf_head.hf_scrolled { box-shadow: 0 6px 20px rgba(11, 59, 55, .08); }
.hf_head_in { display: flex; align-items: center; gap: 30px; height: 76px; }
.hf_logo img { height: 44px; width: auto; display: block; }
.hf_nav { display: flex; align-items: center; gap: 4px; }
.hf_nav a {
    position: relative; padding: 8px 16px; border-radius: 8px; font-size: 15.5px; font-weight: 600; color: var(--hf-text);
    transition: background .18s ease, color .18s ease;
}
.hf_nav a:hover { background: var(--hf-mint); color: var(--hf-teal); }
.hf_nav a.on { color: var(--hf-teal); }
.hf_nav a.on::after { content: ''; position: absolute; left: 16px; right: 16px; bottom: -19px; height: 3px; border-radius: 3px 3px 0 0; background: var(--hf-teal); }
.hf_head_r { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.hf_tel { display: flex; align-items: center; gap: 9px; padding-right: 14px; margin-right: 2px; border-right: 1px solid var(--hf-line); color: var(--hf-ink); }
.hf_tel i { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--hf-orange-soft); color: var(--hf-orange); font-size: 14px; }
.hf_tel span { display: flex; flex-direction: column; font-size: 15px; font-weight: 800; line-height: 1.2; letter-spacing: .3px; }
.hf_tel em { font-style: normal; font-size: 11.5px; font-weight: 400; color: var(--hf-muted); letter-spacing: 0; }
.hf_user { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; font-size: 14px; color: var(--hf-text); border-radius: 8px; }
.hf_user:hover { color: var(--hf-teal); background: var(--hf-mint); }
.hf_join {
    display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: 9px;
    background: var(--hf-orange); color: #fff; font-size: 14px; font-weight: 700; box-shadow: 0 8px 18px rgba(240, 138, 36, .25);
}
.hf_join:hover { background: var(--hf-orange-d); color: #fff; }
.hf_burger { display: none; width: 40px; height: 40px; border: 1px solid var(--hf-line); border-radius: 8px; background: #fff; color: var(--hf-ink); }

.hf_mask { position: fixed; inset: 0; background: rgba(11, 59, 55, .45); opacity: 0; visibility: hidden; transition: .2s; z-index: 98; }
.hf_mask.on { opacity: 1; visibility: visible; }
.hf_drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 280px; background: #fff; z-index: 99; padding: 16px 20px; transform: translateX(100%); transition: transform .25s ease; overflow-y: auto; }
.hf_drawer.on { transform: none; }
.hf_drawer_top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.hf_drawer_top button { width: 34px; height: 34px; border: none; border-radius: 8px; background: var(--hf-mint); color: var(--hf-teal); }
.hf_drawer > a { display: block; padding: 12px 2px; border-bottom: 1px solid var(--hf-line); font-size: 15px; color: var(--hf-ink); }
.hf_drawer_tel { margin-top: 16px; font-size: 13px; color: var(--hf-muted); }
.hf_drawer_tel b { display: block; font-size: 18px; color: var(--hf-orange); }

/* ---------- 页脚 ---------- */
.hf_foot { background: var(--hf-teal-dd); color: #A9C4BF; font-size: 13.5px; margin-top: 64px; }
.hf_foot_cta {
    display: flex; align-items: center; gap: 24px; padding: 26px 32px; transform: translateY(-40px); margin-bottom: -16px;
    background: linear-gradient(120deg, var(--hf-teal) 0%, var(--hf-teal-2) 100%); border-radius: 16px; box-shadow: 0 16px 36px rgba(11, 59, 55, .22); color: #DDF1EC;
}
.hf_foot_cta h3 { margin: 0 0 4px; font-size: 20px; font-weight: 800; color: #fff; }
.hf_foot_cta p { margin: 0; font-size: 13.5px; }
.hf_foot_cta a { margin-left: auto; flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 10px; background: var(--hf-orange); color: #fff; font-size: 15px; font-weight: 700; }
.hf_foot_cta a:hover { background: var(--hf-orange-d); color: #fff; }
.hf_foot_main { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr 1.6fr; gap: 34px; padding: 10px 0 30px; }
.hf_foot_brand img { height: 44px; width: auto; margin-bottom: 14px; }
.hf_foot_brand p { line-height: 1.9; color: #94B3AD; margin: 0; }
.hf_foot_col h5 { font-size: 15px; font-weight: 700; color: #fff; margin: 4px 0 16px; }
.hf_foot_col a { display: block; margin-bottom: 10px; color: #A9C4BF; }
.hf_foot_col a:hover { color: #fff; }
.hf_foot_contact p { display: flex; gap: 9px; margin: 0 0 9px; line-height: 1.7; color: #C8DDD8; }
.hf_foot_contact i { width: 14px; margin-top: 5px; color: var(--hf-orange); }
.hf_foot_notice { display: flex; gap: 10px; padding: 14px 18px; border-radius: 10px; background: rgba(255, 255, 255, .05); font-size: 12.5px; line-height: 1.85; color: #94B3AD; }
.hf_foot_notice i { margin-top: 5px; color: #F7B771; }
.hf_foot_copy { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 18px 0 22px; margin-top: 20px; border-top: 1px solid rgba(255, 255, 255, .08); font-size: 12.5px; color: #7FA19A; }
.hf_foot_copy a { color: #C8DDD8; }
.hf_foot_copy a:hover { color: #fff; }
.hf_foot_copy_r { margin-left: auto; }

/* ---------- 页头（内页） ---------- */
.hf_ph { position: relative; padding: 26px 0 30px; background: linear-gradient(120deg, #0B3B37 0%, #0F6E66 70%, #2FA597 100%); color: #CFE6E1; overflow: hidden; }
.hf_ph::after {
    content: ''; position: absolute; right: -60px; bottom: -80px; width: 380px; height: 380px; border-radius: 50%;
    border: 60px solid rgba(255, 255, 255, .05); pointer-events: none;
}
.hf_ph .hf_wrap { position: relative; z-index: 1; }
.hf_crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; color: #9CC6BE; margin-bottom: 14px; }
.hf_crumb a:hover { color: #fff; }
.hf_crumb i { font-size: 10px; opacity: .7; }
.hf_crumb b { color: #fff; font-weight: 600; }
.hf_ph_row { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; }
.hf_ph h1 { margin: 0 0 8px; font-size: 28px; font-weight: 800; color: #fff; }
.hf_ph p { margin: 0; font-size: 14px; line-height: 1.85; max-width: 760px; }
.hf_ph_nums { display: flex; gap: 10px; flex-shrink: 0; }
.hf_ph_nums div { min-width: 100px; padding: 12px 16px; text-align: center; border-radius: 12px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); }
.hf_ph_nums b { display: block; font-size: 24px; font-weight: 800; color: #FFC58A; line-height: 1.2; }
.hf_ph_nums span { font-size: 12px; color: #BFDDD6; }

/* ---------- 筛选条 ---------- */
.hf_filter { background: #fff; border-bottom: 1px solid var(--hf-line); }
.hf_filter_in { display: flex; align-items: center; gap: 16px; min-height: 62px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
.hf_seg { display: flex; gap: 6px; }
.hf_seg a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 8px; font-size: 14px; font-weight: 600; color: var(--hf-text); border: 1px solid var(--hf-line); background: #fff; }
.hf_seg a i { color: var(--hf-teal); }
.hf_seg a.on { background: var(--hf-teal); border-color: var(--hf-teal); color: #fff; }
.hf_seg a.on i { color: #fff; }
.hf_seg a:not(.on):hover { border-color: var(--hf-teal); color: var(--hf-teal); }
.hf_filter_r { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.hf_sorts { display: flex; border: 1px solid var(--hf-line); border-radius: 8px; overflow: hidden; }
.hf_sorts a { padding: 7px 14px; font-size: 13px; color: var(--hf-text); }
.hf_sorts a + a { border-left: 1px solid var(--hf-line); }
.hf_sorts a.on { background: var(--hf-mint); color: var(--hf-teal); font-weight: 700; }
.hf_find { display: flex; height: 38px; border: 1.5px solid var(--hf-teal); border-radius: 9px; overflow: hidden; background: #fff; }
.hf_find input { width: 210px; border: none; outline: none; padding: 0 12px; font-size: 13.5px; color: var(--hf-ink); }
.hf_find button { border: none; padding: 0 16px; background: var(--hf-teal); color: #fff; font-size: 13.5px; font-weight: 700; }

/* ---------- 布局：主区 + 侧栏 ---------- */
.hf_layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; padding-top: 26px; }
.hf_side { display: flex; flex-direction: column; gap: 16px; }
.hf_count { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-size: 14px; color: var(--hf-muted); }
.hf_count b { color: var(--hf-orange); font-size: 17px; margin: 0 3px; }

/* ---------- 房源行（横向，列表页） ---------- */
.hf_rows { display: flex; flex-direction: column; gap: 14px; }
.hf_row {
    display: grid; grid-template-columns: 260px minmax(0, 1fr) 170px; gap: 22px; padding: 16px; background: #fff;
    border: 1px solid var(--hf-line); border-radius: 14px; transition: border-color .2s ease, box-shadow .2s ease;
}
.hf_row:hover { border-color: #BFDDD6; box-shadow: var(--zh-shadow-card-hover); }
.hf_row_img { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--hf-mint); }
.hf_row_img img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.hf_row:hover .hf_row_img img { transform: scale(1.05); }
.hf_tag { position: absolute; left: 10px; top: 10px; padding: 3px 10px; border-radius: 6px; font-size: 12px; font-weight: 700; color: #fff; background: rgba(15, 110, 102, .92); }
.hf_tag.office { background: rgba(31, 45, 58, .88); }
.hf_row_body { display: flex; flex-direction: column; gap: 10px; min-width: 0; padding-top: 2px; }
.hf_row_body h3 { margin: 0; font-size: 17.5px; line-height: 1.5; font-weight: 700; }
.hf_row_body h3 a { color: var(--hf-ink); }
.hf_row:hover h3 a { color: var(--hf-teal); }
.hf_chips { display: flex; flex-wrap: wrap; gap: 6px; }
.hf_chips span { padding: 3px 10px; border-radius: 6px; font-size: 12.5px; background: var(--hf-mint-2); color: #3E6A63; }
.hf_loc { font-size: 13px; color: var(--hf-muted); }
.hf_loc i { color: var(--hf-teal); margin-right: 5px; }
.hf_who { margin-top: auto; display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--hf-muted); }
.hf_who_ava {
    width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
    background: var(--hf-teal); color: #fff; font-size: 12.5px; font-weight: 700; font-style: normal;
}
.hf_who b { color: var(--hf-ink); font-weight: 600; }
.hf_row_price { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 8px; border-left: 1px dashed var(--hf-line); padding-left: 18px; text-align: right; }
.hf_price { color: var(--hf-orange); font-weight: 800; line-height: 1.1; }
.hf_price b { font-size: 28px; }
.hf_price small { font-size: 13px; font-weight: 600; margin-left: 2px; }
.hf_row_price em { font-style: normal; font-size: 12.5px; color: var(--hf-muted); }
.hf_row_price a { margin-top: 6px; padding: 7px 16px; border-radius: 8px; border: 1px solid var(--hf-teal); color: var(--hf-teal); font-size: 13px; font-weight: 600; }
.hf_row_price a:hover { background: var(--hf-teal); color: #fff; }

/* ---------- 房源卡（竖向，首页 / 推荐） ---------- */
.hf_cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.hf_card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--hf-line); border-radius: 14px; overflow: hidden; transition: transform .2s ease, box-shadow .2s ease; }
.hf_card:hover { transform: translateY(-4px); box-shadow: var(--zh-shadow-card-hover); }
.hf_card_img { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--hf-mint); }
.hf_card_img img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.hf_card:hover .hf_card_img img { transform: scale(1.05); }
.hf_card_price { position: absolute; left: 10px; bottom: 10px; padding: 4px 11px; border-radius: 8px; background: var(--hf-orange); color: #fff; font-size: 15px; font-weight: 800; box-shadow: 0 6px 14px rgba(0, 0, 0, .18); }
.hf_card_body { display: flex; flex-direction: column; gap: 8px; padding: 14px 15px 15px; flex: 1; }
.hf_card_body strong { font-size: 15px; line-height: 1.55; color: var(--hf-ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 46px; }
.hf_card:hover strong { color: var(--hf-teal); }
.hf_card_meta { font-size: 12.5px; color: var(--hf-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hf_card .hf_who { padding-top: 10px; border-top: 1px dashed var(--hf-line); font-size: 12.5px; }
.hf_card .hf_who span { margin-left: auto; }

/* ---------- 侧栏盒 ---------- */
.hf_box { background: #fff; border: 1px solid var(--hf-line); border-radius: 14px; padding: 16px 18px; }
.hf_box_hd { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; padding-bottom: 10px; border-bottom: 1px solid var(--hf-line); font-size: 15px; font-weight: 800; color: var(--hf-ink); }
.hf_box_hd i { color: var(--hf-teal); }
.hf_mini a { display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: 10px; padding: 8px 0; }
.hf_mini a + a { border-top: 1px dashed var(--hf-line); }
.hf_mini img { width: 74px; height: 56px; object-fit: cover; border-radius: 8px; }
.hf_mini strong { font-size: 13px; line-height: 1.5; color: var(--hf-ink); font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hf_mini em { display: block; font-style: normal; font-size: 12.5px; color: var(--hf-orange); font-weight: 700; margin-top: 2px; }
.hf_mini a:hover strong { color: var(--hf-teal); }
.hf_box_cta { background: linear-gradient(150deg, #FFF1E2 0%, #FFF8F0 100%); border-color: #F6D9B8; }
.hf_box_cta h4 { margin: 0 0 6px; font-size: 16px; font-weight: 800; color: #8A4A0E; }
.hf_box_cta p { margin: 0 0 12px; font-size: 13px; line-height: 1.8; color: #8F6A45; }
.hf_box_cta a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 18px; border-radius: 8px; background: var(--hf-orange); color: #fff; font-size: 13.5px; font-weight: 700; }
.hf_box_tips li { position: relative; padding-left: 16px; margin-bottom: 8px; font-size: 13px; line-height: 1.75; color: var(--hf-text); list-style: none; }
.hf_box_tips li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--hf-orange); }
.hf_box_tips ul { padding: 0; margin: 0; }

/* ---------- 空状态 / 分页 ---------- */
.hf_empty { padding: 60px 20px; text-align: center; background: #fff; border: 1px dashed var(--hf-line); border-radius: 14px; }
.hf_empty i { font-size: 40px; color: #BFDDD6; margin-bottom: 12px; }
.hf_empty h3 { font-size: 17px; margin: 0 0 6px; color: var(--hf-ink); }
.hf_empty p { font-size: 13.5px; color: var(--hf-muted); margin: 0 0 16px; }
.hf_empty a { display: inline-block; padding: 8px 22px; border-radius: 8px; background: var(--hf-teal); color: #fff; }
.hf_pager { margin-top: 26px; }
.hf_pager .zh_pagination { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.hf_pager .zh_pagination a, .hf_pager .zh_pagination span {
    min-width: 40px; height: 40px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 9px; border: 1px solid var(--hf-line); background: #fff; font-size: 14px; color: var(--hf-text);
}
.hf_pager .zh_pagination a:hover { border-color: var(--hf-teal); color: var(--hf-teal); }
.hf_pager .zh_pagination .zh_page_active { background: var(--hf-teal); border-color: var(--hf-teal); color: #fff; font-weight: 700; }
.hf_pager .zh_pagination .zh_page_disabled { color: #C2CCCA; }

/* ---------- 正文 ---------- */
.hf_prose { font-size: 15px; line-height: 2; color: #34424E; }
.hf_prose p { margin: 0 0 12px; }
.hf_prose h2, .hf_prose h3 { font-size: 17px; font-weight: 800; color: var(--hf-ink); margin: 24px 0 10px; padding-left: 12px; border-left: 4px solid var(--hf-teal); line-height: 1.4; }
.hf_prose ul, .hf_prose ol { margin: 0 0 14px; padding-left: 22px; }
.hf_prose ul { list-style: disc; }
.hf_prose ol { list-style: decimal; }
.hf_prose li { margin-bottom: 6px; }
.hf_prose li::marker { color: var(--hf-teal); }
.hf_prose strong { color: var(--hf-ink); }
.hf_prose img { max-width: 100%; height: auto; border-radius: 10px; display: block; }
.hf_prose table { width: 100%; border-collapse: collapse; margin: 6px 0 16px; font-size: 14px; }
.hf_prose th { background: var(--hf-mint); color: #1F5A52; text-align: left; padding: 10px 12px; border: 1px solid #CFE3DE; }
.hf_prose td { padding: 9px 12px; border: 1px solid var(--hf-line); }

/* ---------- 窄屏兜底（管局只看 PC） ---------- */
@media (max-width: 1180px) {
    .hf_tel { display: none; }
    .hf_cards { grid-template-columns: repeat(3, 1fr); }
    .hf_foot_main { grid-template-columns: 1fr 1fr 1fr; }
    .hf_foot_brand { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
    .hf_nav, .hf_user { display: none; }
    .hf_burger { display: inline-flex; align-items: center; justify-content: center; }
    .hf_layout { grid-template-columns: 1fr; }
    .hf_row { grid-template-columns: 1fr; }
    .hf_row_price { border-left: none; padding-left: 0; align-items: flex-start; text-align: left; }
    .hf_cards { grid-template-columns: repeat(2, 1fr); }
    .hf_ph_row { flex-direction: column; align-items: flex-start; }
    .hf_foot_cta { flex-direction: column; align-items: flex-start; }
    .hf_foot_cta a { margin-left: 0; }
    .hf_filter_r { margin-left: 0; width: 100%; }
}
@media (max-width: 560px) {
    .hf_head_in { height: 64px; gap: 12px; }
    .hf_logo img { height: 36px; }
    .hf_join { padding: 8px 12px; font-size: 13px; }
    .hf_cards { grid-template-columns: 1fr; }
    .hf_foot_main { grid-template-columns: 1fr 1fr; }
}
