/* ========================================
   高新e企通 — 视觉设计系统 v2.0
   商务简洁风格 · 微信服务号 H5
   ======================================== */

/* ---- Design Tokens ---- */
:root {
  /* Neutral palette */
  --gray-50:  #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-700: #374151;
  --gray-900: #111827;

  /* Brand */
  --brand:        #1e40af;
  --brand-light:  #eff6ff;
  --brand-dark:   #1e3a8a;

  /* Semantic */
  --success: #059669;
  --success-bg: #ecfdf5;
  --warn:    #d97706;
  --warn-bg: #fffbeb;
  --danger:  #dc2626;

  /* Application */
  --bg:           var(--gray-100);
  --surface:      #ffffff;
  --border:       var(--gray-200);
  --border-light: var(--gray-100);
  --text:         var(--gray-900);
  --text-secondary: var(--gray-500);
  --text-tertiary:  var(--gray-400);

  --shadow-sm:  0 1px 2px rgba(0,0,0,0.04);
  --shadow:     0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:  0 4px 6px rgba(0,0,0,0.05), 0 2px 4px rgba(0,0,0,0.04);

  --radius-sm: 8px;
  --radius:    12px;
  --radius-lg: 16px;

  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  --max-width: 480px;
  --header-h: 48px;
  --nav-h: 56px;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  max-width: var(--max-width);
  margin: 0 auto;
  min-height: 100vh;
  padding-bottom: calc(var(--nav-h) + 20px);
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button { border: none; background: none; font-family: inherit; cursor: pointer; }
input, select { font-family: inherit; font-size: 15px; }

/* ---- Header ---- */
.page-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: var(--header-h);
  display: flex; align-items: center; justify-content: center;
  padding: 0 16px;
}
.page-header .back-btn {
  position: absolute; left: 12px;
  color: var(--brand); font-size: 18px; font-weight: 500;
  display: flex; align-items: center; gap: 4px;
}
.page-header .back-btn span { font-size: 14px; }
.page-header h1 { font-size: 16px; font-weight: 600; color: var(--text); letter-spacing: 0.5px; }

/* ---- Hero (Homepage) ---- */
.hero {
  position: relative;
  height: 200px;
  background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 40%, #3b82f6 100%);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: #ffffff;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: url('https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?w=800&q=80') center/cover no-repeat;
  opacity: 0.18;
}
.hero::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 60px;
  background: linear-gradient(transparent, rgba(0,0,0,0.15));
}
.hero .brand {
  position: relative; z-index: 1;
  font-size: 24px; font-weight: 700; letter-spacing: 2px;
}
.hero .brand span { color: #93c5fd; }
.hero .tagline {
  position: relative; z-index: 1;
  font-size: 13px; opacity: 0.85; margin-top: 4px; font-weight: 400;
}
.hero .sub-tagline {
  position: relative; z-index: 1;
  font-size: 11px; opacity: 0.55; margin-top: 2px;
}

/* ---- Search Bar ---- */
.search-bar {
  display: flex; align-items: center; gap: 10px;
  margin: -20px 16px 0;
  padding: 10px 16px;
  background: var(--surface);
  border-radius: 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  position: relative; z-index: 2;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.search-bar:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(30,64,175,0.1), var(--shadow-md);
}
.search-bar .search-icon { font-size: 17px; flex-shrink: 0; opacity: 0.4; }
.search-bar input {
  flex: 1; border: none; outline: none;
  font-size: 15px; color: var(--text);
  background: transparent; min-width: 0;
}
.search-bar input::placeholder { color: var(--text-tertiary); }
.search-bar .search-clear {
  flex-shrink: 0; width: 22px; height: 22px;
  border-radius: 50%; background: var(--gray-200);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; color: var(--text-secondary);
  cursor: pointer; transition: background 0.15s;
}
.search-bar .search-clear:active { background: var(--gray-300); }

/* ---- Stats Row ---- */
.stats-row {
  padding: 14px 16px 2px;
  font-size: 12px; color: var(--text-tertiary); font-weight: 500;
}

/* ---- Update Feed ---- */
.update-feed { padding: 8px 16px 8px; }
.update-item {
  display: block;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 18px 16px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: box-shadow 0.15s, transform 0.15s;
}
.update-item:active { box-shadow: var(--shadow-md); transform: scale(0.99); }
.update-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 10px; border-radius: 4px;
  font-size: 11px; font-weight: 600; margin-bottom: 8px;
  letter-spacing: 0.3px;
}
.badge-blue { background: var(--brand-light); color: var(--brand); }
.badge-green { background: var(--success-bg); color: var(--success); }
.badge-purple { background: #faf5ff; color: #7c3aed; }
.update-title {
  font-size: 15px; font-weight: 600; color: var(--text);
  line-height: 1.5; margin-bottom: 6px;
  display: flex; align-items: flex-start; gap: 6px;
}
.new-dot {
  flex-shrink: 0; width: 6px; height: 6px;
  background: var(--danger); border-radius: 50%;
  margin-top: 7px;
}
.update-summary {
  font-size: 13px; color: var(--text-secondary);
  line-height: 1.7; margin-bottom: 8px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.update-meta {
  display: flex; gap: 10px; align-items: center;
  font-size: 11px; color: var(--text-tertiary);
  flex-wrap: wrap;
}
.update-meta .update-source {
  background: var(--gray-50); padding: 1px 8px; border-radius: 4px;
  color: var(--text-secondary);
}

/* ---- Page Content ---- */
.page-content { padding: 16px; }

/* ---- Filter Bar ---- */
.filter-bar {
  display: flex; gap: 8px; padding: 12px 16px;
  background: var(--surface);
  position: sticky; top: var(--header-h); z-index: 50;
  border-bottom: 1px solid var(--border);
}
.filter-bar select {
  flex: 1; padding: 9px 12px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-size: 13px;
  background: var(--gray-50); color: var(--text);
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239ca3af' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
  padding-right: 32px;
}

/* ---- Property Card ---- */
.property-list { padding: 12px 16px; }
.property-card {
  background: var(--surface); border-radius: var(--radius);
  margin-bottom: 14px; box-shadow: var(--shadow-sm);
  border: 1px solid var(--border); overflow: hidden;
  transition: box-shadow 0.15s;
}
.property-card:active { box-shadow: var(--shadow-md); }
.property-card .p-img {
  width: 100%; height: 180px;
  background: var(--gray-100) url('https://images.unsplash.com/photo-1497366216548-37526070297c?w=600&q=80') center/cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.9); font-size: 14px; font-weight: 500;
  position: relative; text-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
.property-card .p-img::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05) 0%, rgba(0,0,0,0.25) 100%);
}
.property-card .p-img .p-type-tag {
  position: absolute; top: 12px; left: 12px; z-index: 1;
  padding: 4px 12px; border-radius: 5px;
  font-size: 11px; font-weight: 600; color: #fff;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.p-type-tag.office { background: rgba(37,99,235,0.85); }
.p-type-tag.factory { background: rgba(5,150,105,0.85); }
.p-type-tag.shop { background: rgba(217,119,6,0.85); }
.p-type-tag.warehouse { background: rgba(124,58,237,0.85); }
.property-card .p-info { padding: 16px; }
.property-card .p-title { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.property-card .p-meta {
  display: flex; gap: 16px; margin-bottom: 8px;
  font-size: 12px; color: var(--text-secondary);
}
.property-card .p-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.property-card .p-tags span {
  padding: 2px 8px; border-radius: 4px;
  font-size: 11px; background: var(--gray-50); color: var(--text-secondary);
}
.property-card .p-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 12px; border-top: 1px solid var(--border-light);
}
.property-card .p-price { font-size: 18px; font-weight: 700; color: var(--danger); }
.property-card .p-price .unit { font-size: 12px; font-weight: 400; color: var(--text-secondary); }
.property-card .p-contact-btn {
  padding: 7px 20px; background: var(--brand); color: #fff;
  border-radius: 18px; font-size: 12px; font-weight: 600;
  letter-spacing: 0.5px; transition: background 0.15s;
}
.property-card .p-contact-btn:active { background: var(--brand-dark); }

/* ---- Policy Page ---- */
.policy-tabs {
  display: flex; gap: 6px; padding: 12px 16px;
  overflow-x: auto; background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.policy-tabs .tab {
  padding: 8px 16px; font-size: 13px; color: var(--text-secondary);
  white-space: nowrap; border-radius: 18px;
  background: var(--gray-50); font-weight: 500;
  transition: all 0.2s; cursor: pointer;
}
.policy-tabs .tab.active { color: #fff; background: var(--brand); font-weight: 600; }

.policy-article {
  background: var(--surface); border-radius: var(--radius);
  padding: 18px 16px; margin-bottom: 12px;
  box-shadow: var(--shadow-sm); border: 1px solid var(--border);
}
.policy-article .pa-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.policy-article .pa-tag {
  padding: 2px 10px; border-radius: 4px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.3px;
}
.pa-tag.tax { background: var(--warn-bg); color: var(--warn); }
.pa-tag.subsidy { background: var(--success-bg); color: var(--success); }
.pa-tag.talent { background: var(--brand-light); color: var(--brand); }
.pa-tag.tech { background: #faf5ff; color: #7c3aed; }
.pa-tag.land { background: #fef2f2; color: var(--danger); }
.policy-article .pa-title { font-size: 15px; font-weight: 600; margin-bottom: 6px; line-height: 1.5; }
.policy-article .pa-abstract {
  font-size: 13px; color: var(--text-secondary); line-height: 1.7;
  margin-bottom: 10px;
}
.policy-article .pa-footer {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 11px; color: var(--text-tertiary);
}
.policy-article .pa-link { color: var(--brand); font-weight: 600; }

/* ---- Policy Source Badge ---- */
.policy-source-badge {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 8px; border-radius: 4px;
  font-size: 10px; font-weight: 500;
}
.policy-source-badge.gov { background: var(--brand-light); color: var(--brand); }
.policy-source-badge.media { background: var(--warn-bg); color: var(--warn); }
.policy-source-badge.industry { background: var(--success-bg); color: var(--success); }

/* ---- Service Detail Page ---- */
.service-section { margin-bottom: 20px; }
.service-section .ss-header {
  background: var(--surface); border-radius: var(--radius) var(--radius) 0 0;
  padding: 20px 16px; display: flex; align-items: center; gap: 14px;
  border: 1px solid var(--border); border-bottom: none;
}
.service-section .ss-icon {
  width: 50px; height: 50px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center; font-size: 24px;
  flex-shrink: 0;
}
.service-section .ss-icon.blue { background: var(--brand-light); color: var(--brand); }
.service-section .ss-icon.orange { background: var(--warn-bg); color: var(--warn); }
.service-section .ss-icon.green { background: var(--success-bg); color: var(--success); }
.service-section .ss-icon.purple { background: #faf5ff; color: #7c3aed; }
.service-section .ss-title { font-size: 16px; font-weight: 700; }
.service-section .ss-subtitle { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.service-section .ss-body {
  background: var(--surface); border-radius: 0 0 var(--radius) var(--radius);
  padding: 16px; border: 1px solid var(--border); border-top: none;
}
.service-section .ss-body p { font-size: 13px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 14px; }
.service-section .ss-items {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px;
}
.service-section .ss-item {
  padding: 12px; background: var(--gray-50);
  border-radius: var(--radius-sm); font-size: 13px; color: var(--text);
  text-align: center; font-weight: 500;
}

/* ---- About Page ---- */
.about-hero {
  background: var(--surface); margin: 16px; border-radius: var(--radius);
  padding: 32px 20px; text-align: center;
  box-shadow: var(--shadow-sm); border: 1px solid var(--border);
}
.about-hero .ah-logo {
  width: 68px; height: 68px; margin: 0 auto 14px;
  background: var(--brand); border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 30px; font-weight: 700;
  box-shadow: 0 4px 12px rgba(30,64,175,0.25);
}
.about-hero .ah-name { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
.about-hero .ah-tagline { font-size: 13px; color: var(--text-secondary); }
.about-info { margin: 0 16px; }
.about-info .ai-card {
  background: var(--surface); border-radius: var(--radius);
  padding: 20px 16px; margin-bottom: 12px;
  box-shadow: var(--shadow-sm); border: 1px solid var(--border);
}
.about-info .ai-card h4 {
  font-size: 15px; font-weight: 600; margin-bottom: 12px; color: var(--text);
  display: flex; align-items: center; gap: 6px;
}
.about-info .ai-card p { font-size: 13px; color: var(--text-secondary); line-height: 1.8; }
.about-info .ai-card .contact-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; font-size: 14px; color: var(--text);
  border-bottom: 1px solid var(--border-light);
}
.about-info .ai-card .contact-row:last-child { border-bottom: none; }
.about-info .ai-card .contact-icon { font-size: 17px; width: 28px; text-align: center; }

/* ---- Detail Modal ---- */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.45);
  z-index: 200; display: flex; align-items: flex-end;
  animation: fadeIn 0.2s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-content {
  background: var(--surface); width: 100%; max-width: var(--max-width);
  margin: 0 auto; border-radius: 20px 20px 0 0;
  max-height: 85vh; overflow-y: auto;
  animation: slideUp 0.25s ease;
}
@keyframes slideUp { from { transform: translateY(20px); } to { transform: translateY(0); } }
.modal-content .modal-img {
  width: 100%; height: 220px;
  background: var(--gray-100) url('https://images.unsplash.com/photo-1497366754270-b5f1a1e3b01a?w=600&q=80') center/cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.9); font-size: 14px; font-weight: 500;
  text-shadow: 0 1px 4px rgba(0,0,0,0.3);
  position: relative;
}
.modal-content .modal-img::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05), rgba(0,0,0,0.2));
}
.modal-content .modal-body { padding: 22px 16px; }
.modal-content .modal-close {
  position: absolute; right: 14px; top: 14px; z-index: 1;
  width: 30px; height: 30px; background: rgba(0,0,0,0.35);
  border-radius: 50%; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; backdrop-filter: blur(4px);
}
.modal-content .modal-title { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.modal-content .modal-meta { display: flex; gap: 16px; margin-bottom: 12px; font-size: 13px; color: var(--text-secondary); }
.modal-content .modal-price { font-size: 22px; font-weight: 700; color: var(--danger); margin-bottom: 12px; }
.modal-content .modal-features { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.modal-content .modal-features span {
  padding: 4px 12px; border-radius: 14px; font-size: 12px;
  background: var(--gray-50); color: var(--text-secondary);
}
.modal-content .modal-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 18px; }
.modal-content .modal-cta {
  display: block; width: 100%; padding: 14px;
  background: var(--brand); color: #fff;
  border-radius: var(--radius); font-size: 16px; font-weight: 600;
  text-align: center; letter-spacing: 1px;
  transition: background 0.15s;
}
.modal-content .modal-cta:active { background: var(--brand-dark); }

/* ---- CTA Banner ---- */
.cta-banner {
  margin: 16px; padding: 24px 20px;
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  border-radius: var(--radius); color: #fff; text-align: center;
  box-shadow: 0 4px 16px rgba(30,64,175,0.2);
}
.cta-banner h4 { font-size: 16px; margin-bottom: 4px; font-weight: 600; }
.cta-banner p { font-size: 12px; opacity: 0.85; margin-bottom: 14px; }
.cta-banner .cta-btn {
  display: inline-block; padding: 10px 28px;
  background: #fff; color: var(--brand);
  border-radius: 22px; font-size: 14px; font-weight: 600;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: transform 0.15s;
}
.cta-banner .cta-btn:active { transform: scale(0.97); }

/* ---- Bottom Navigation ---- */
.bottom-nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: var(--max-width); height: var(--nav-h);
  background: rgba(255,255,255,0.94);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border); display: flex; z-index: 100;
}
.bottom-nav a {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  color: var(--text-tertiary); font-size: 10px;
  transition: color 0.2s; gap: 2px; font-weight: 500;
}
.bottom-nav a .nav-icon { font-size: 20px; line-height: 1; }
.bottom-nav a.active { color: var(--brand); font-weight: 600; }

/* ---- Contact Float ---- */
.contact-float {
  position: fixed; right: 16px; bottom: calc(var(--nav-h) + 20px);
  width: 50px; height: 50px; border-radius: 50%;
  background: var(--brand); color: #fff; display: flex;
  align-items: center; justify-content: center;
  font-size: 22px; box-shadow: 0 4px 16px rgba(30,64,175,0.35);
  z-index: 90; transition: transform 0.15s;
}
.contact-float:active { transform: scale(0.9); }

/* ---- Toast ---- */
.toast {
  position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%);
  background: rgba(17,24,39,0.88); color: #fff;
  padding: 10px 24px; border-radius: 22px; font-size: 14px;
  z-index: 300; pointer-events: none;
  animation: toastFade 2.5s ease forwards;
}
@keyframes toastFade {
  0% { opacity: 0; transform: translate(-50%,-50%) scale(0.9); }
  10% { opacity: 1; transform: translate(-50%,-50%) scale(1); }
  80% { opacity: 1; }
  100% { opacity: 0; }
}

/* ---- Empty State ---- */
.empty-state { text-align: center; padding: 48px 20px; color: var(--text-tertiary); }
.empty-state .empty-icon { font-size: 48px; margin-bottom: 12px; }
.empty-state p { font-size: 14px; }

/* ---- Section Title (通用) ---- */
.section-title {
  padding: 20px 16px 12px;
  display: flex; align-items: center; justify-content: space-between;
}
.section-title h3 {
  font-size: 17px; font-weight: 700; color: var(--text);
  position: relative; padding-left: 12px;
}
.section-title h3::before {
  content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 18px; background: var(--brand); border-radius: 2px;
}
.section-title .more { font-size: 12px; color: var(--brand); font-weight: 500; }

/* ---- 移动端边框 ---- */
@media (min-width: 481px) {
  body { border-left: 1px solid var(--border); border-right: 1px solid var(--border); }
}
