/* 邯郸房讯网 - 本地化设计系统（零外部CDN依赖，375px 移动端无横向滚动） */
:root {
  --brand: #165DAA;
  --brand-dark: #0F437E;
  --brand-soft: #EEF5FC;
  --accent: #E86A0C;
  --accent-dark: #C25104;
  --accent-soft: #FFF4EB;
  --bg: #F6F8FB;
  --surface: #FFFFFF;
  --text: #1E293B;
  --text-sub: #475569;
  --text-muted: #64748B;
  --border: #E2E8F0;
  --border-strong: #CBD5E1;
  --success: #0F766E;
  --success-soft: #ECFDF5;
  --footer-bg: #0F172A;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --container: 1180px;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  overflow-x: clip;
}

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--brand);
  text-decoration: none;
  transition: color 0.16s ease, background-color 0.16s ease, border-color 0.16s ease;
}

a:hover {
  color: var(--accent);
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 18px;
}

/* 顶部导航栏 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
}

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

.brand-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
}

.brand-city-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.main-nav a {
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--brand);
  background: var(--brand-soft);
}

.main-nav a.active {
  font-weight: 600;
}

.header-search {
  display: flex;
  align-items: center;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: #F8FAFC;
  padding: 3px 4px 3px 12px;
  min-width: 190px;
  max-width: 230px;
}

.header-search input {
  border: 0;
  background: transparent;
  outline: none;
  font-size: 13px;
  color: var(--text);
  width: 100%;
  min-width: 0;
}

.header-search button {
  border: 0;
  background: var(--brand);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
}

.header-search button:hover {
  background: var(--brand-dark);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: #fff;
  color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
}

/* 移动端抽屉导航 */
.mobile-drawer {
  display: none;
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 12px 18px 18px;
}

.mobile-drawer.open {
  display: block;
}

.mobile-nav-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.mobile-nav-grid a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
}

.mobile-nav-grid a.active {
  background: var(--brand);
  color: #fff;
}

.mobile-search {
  display: flex;
  gap: 8px;
}

.mobile-search input {
  flex: 1;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  font-size: 14px;
}

.mobile-search button {
  padding: 9px 16px;
  border: 0;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}

/* 首页顶部公告通栏（位于导航栏正下方） */
.announce-bar {
  background: linear-gradient(90deg, #FFF7ED 0%, #FFFBF5 50%, #EEF5FC 100%);
  border-bottom: 1px solid #FED7AA;
  padding: 9px 0;
}

.announce-inner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13.5px;
  color: #7C2D12;
  line-height: 1.55;
}

.announce-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px;
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

.announce-text {
  margin: 0;
  word-break: break-word;
}

/* 首页 Hero */
.hero {
  background: linear-gradient(135deg, #0D3A6B 0%, #165DAA 58%, #1C75C8 100%);
  color: #fff;
  padding: 36px 0 42px;
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.95fr);
  gap: 28px;
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 12.5px;
  font-weight: 600;
  margin-bottom: 14px;
}

.hero h1 {
  margin: 0 0 12px;
  font-size: clamp(24px, 3.2vw, 36px);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.hero-lead {
  margin: 0 0 20px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.9);
  max-width: 600px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

.btn-accent {
  background: var(--accent);
  color: #fff;
}

.btn-accent:hover {
  background: var(--accent-dark);
  color: #fff;
}

.btn-brand {
  background: var(--brand);
  color: #fff;
}

.btn-brand:hover {
  background: var(--brand-dark);
  color: #fff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.24);
  color: #fff;
}

.btn-outline {
  background: #fff;
  color: var(--brand);
  border-color: var(--border-strong);
}

.btn-outline:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand-dark);
}

.hero-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.hero-kpi {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  padding: 11px 12px;
}

.hero-kpi-val {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.25;
  color: #FFE0B8;
}

.hero-kpi-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 2px;
}

.hero-panel {
  background: #fff;
  color: var(--text);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-md);
}

.hero-panel-title {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 700;
  color: var(--brand-dark);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.quick-tool-list {
  display: grid;
  gap: 10px;
}

.quick-tool-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #FAFBFD;
  color: var(--text);
}

.quick-tool-item:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand-dark);
}

.quick-tool-name {
  font-size: 14.5px;
  font-weight: 700;
  display: block;
}

.quick-tool-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.quick-tool-arrow {
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
}

/* 通用区块与卡片 */
.section {
  padding: 34px 0;
}

.section-alt {
  background: #FFFFFF;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.section-title {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.section-sub {
  margin: 4px 0 0;
  font-size: 13.5px;
  color: var(--text-muted);
}

.section-more {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--brand);
  white-space: nowrap;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  min-width: 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

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

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

/* 标签与徽章 */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}

.badge-blue {
  background: var(--brand-soft);
  color: var(--brand);
}

.badge-orange {
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.badge-green {
  background: var(--success-soft);
  color: var(--success);
}

.badge-gray {
  background: #F1F5F9;
  color: #475569;
}

/* 数据表格（375px 安全横滑容器） */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: #fff;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  min-width: 600px;
}

.data-table th,
.data-table td {
  padding: 11px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  background: #F8FAFC;
  font-weight: 700;
  color: var(--text-sub);
  white-space: nowrap;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.price-num {
  color: var(--accent-dark);
  font-weight: 700;
  white-space: nowrap;
}

.price-blue {
  color: var(--brand);
  font-weight: 700;
  white-space: nowrap;
}

/* SVG 图表容器 */
.chart-box {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
}

.fx-chart-svg {
  width: 100%;
  height: auto;
}

/* 楼盘卡片 */
.project-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
  min-width: 0;
}

.project-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #BFDBFE;
}

.project-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.project-name {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.35;
}

.project-name a {
  color: var(--text);
}

.project-name a:hover {
  color: var(--brand);
}

.project-price {
  font-size: 17px;
  font-weight: 800;
  color: var(--accent);
  white-space: nowrap;
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.project-desc {
  margin: 0 0 12px;
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.6;
}

.project-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  font-size: 12.5px;
  color: var(--text-muted);
}

/* 文章卡片与列表 */
.article-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  min-width: 0;
}

.article-card h3 {
  margin: 8px 0 8px;
  font-size: 16.5px;
  line-height: 1.4;
}

.article-card h3 a {
  color: var(--text);
}

.article-card h3 a:hover {
  color: var(--brand);
}

.article-excerpt {
  margin: 0 0 12px;
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.6;
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--text-muted);
}

/* 筛选条与面包屑 */
.page-banner {
  background: linear-gradient(135deg, #103F73 0%, #165DAA 100%);
  color: #fff;
  padding: 26px 0;
}

.page-banner h1 {
  margin: 6px 0 8px;
  font-size: clamp(22px, 2.8vw, 30px);
  line-height: 1.3;
}

.page-banner p {
  margin: 0;
  font-size: 14.5px;
  color: rgba(255, 255, 255, 0.88);
  max-width: 760px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.8);
}

.breadcrumb a {
  color: rgba(255, 255, 255, 0.9);
}

.breadcrumb-light {
  color: var(--text-muted);
  margin-bottom: 14px;
}

.breadcrumb-light a {
  color: var(--text-sub);
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  background: #fff;
  color: var(--text-sub);
  border: 1px solid var(--border-strong);
}

.pill:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.pill.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

/* 文章正文与两栏布局 */
.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 24px;
  align-items: start;
}

.article-body {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 26px;
  min-width: 0;
}

.article-body h1 {
  margin: 0 0 12px;
  font-size: clamp(21px, 2.5vw, 28px);
  line-height: 1.35;
}

.article-meta-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  padding-bottom: 14px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
}

.prose h2 {
  margin: 24px 0 10px;
  font-size: 19px;
  color: var(--brand-dark);
  padding-left: 10px;
  border-left: 4px solid var(--accent);
}

.prose h3 {
  margin: 18px 0 8px;
  font-size: 16.5px;
  color: var(--text);
}

.prose p {
  margin: 0 0 14px;
  font-size: 15.5px;
  line-height: 1.8;
  color: #273449;
}

.prose ul,
.prose ol {
  margin: 0 0 16px;
  padding-left: 20px;
}

.prose li {
  margin-bottom: 7px;
  font-size: 15px;
  line-height: 1.75;
  color: #273449;
}

.callout {
  background: var(--brand-soft);
  border: 1px solid #BFDBFE;
  border-left: 4px solid var(--brand);
  border-radius: 8px;
  padding: 14px 16px;
  margin: 18px 0;
  font-size: 14px;
  color: #1E3A5F;
}

.sidebar {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.sidebar-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.sidebar-list li {
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border);
  font-size: 14px;
}

.sidebar-list li:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

/* 置业工具表单与结果卡 */
.tool-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.tool-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 20px;
  align-items: start;
}

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

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

.form-field.full {
  grid-column: 1 / -1;
}

.form-field label {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-sub);
}

.form-field input,
.form-field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  font-size: 14.5px;
  background: #fff;
  color: var(--text);
}

.form-field input:focus,
.form-field select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(22, 93, 170, 0.12);
}

.result-box {
  background: linear-gradient(180deg, #F0F7FF 0%, #FFFFFF 100%);
  border: 1px solid #BFDBFE;
  border-radius: var(--radius-md);
  padding: 20px;
}

.result-primary {
  font-size: 30px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
  margin: 4px 0 14px;
}

.result-rows {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.result-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
}

/* FAQ 折叠 */
.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 15px 18px;
}

.faq-item summary {
  cursor: pointer;
  font-size: 15.5px;
  font-weight: 700;
  color: var(--text);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 20px;
  font-weight: 400;
  color: var(--brand);
  flex-shrink: 0;
}

.faq-item[open] summary::after {
  content: "−";
  color: var(--accent);
}

.faq-answer {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  font-size: 14.5px;
  color: var(--text-sub);
  line-height: 1.75;
}

/* 页脚 */
.site-footer {
  background: var(--footer-bg);
  color: #CBD5E1;
  padding: 36px 0 24px;
  margin-top: 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.footer-title {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
}

.footer-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: #94A3B8;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 7px;
  font-size: 13.5px;
}

.footer-links a {
  color: #CBD5E1;
}

.footer-links a:hover {
  color: #FDBA74;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 18px;
  font-size: 12.5px;
  color: #94A3B8;
}

.footer-bottom a {
  color: #CBD5E1;
}

.footer-bottom a:hover {
  color: #fff;
}

/* 响应式适配（含 375px 窄屏专项优化） */
@media (max-width: 1024px) {
  .main-nav,
  .header-search {
    display: none;
  }
  .nav-toggle {
    display: inline-flex;
  }
  .hero-grid,
  .content-layout,
  .tool-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .container {
    padding: 0 14px;
  }
  .header-inner {
    min-height: 60px;
  }
  .brand-logo {
    height: 36px;
  }
  .brand-city-tag {
    display: none;
  }
  .hero {
    padding: 24px 0 28px;
  }
  .hero-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  .hero-kpi {
    padding: 9px 8px;
  }
  .hero-kpi-val {
    font-size: 15px;
  }
  .hero-kpi-label {
    font-size: 11px;
  }
  .grid-2,
  .grid-3,
  .grid-4,
  .form-grid,
  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .article-body {
    padding: 18px 15px;
  }
  .section {
    padding: 24px 0;
  }
  .section-title {
    font-size: 19px;
  }
  .result-primary {
    font-size: 25px;
  }
}
