/* ============================================================
 * 厦门创业服务地图 - 前台样式
 * ============================================================ */
:root {
  --brand: #1d4ed8;
  --brand-dark: #1e3a8a;
}

body { background: #f4f6fa; font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif; }

/* 顶部导航 */
.site-nav { background: linear-gradient(120deg, #1e3a8a, #1d4ed8); }
.brand-badge {
  display: inline-flex; width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,255,255,.18); color: #fff; font-weight: 700; font-size: 20px;
  align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,.25);
}
.nav-subtitle { font-size: 11px; color: rgba(255,255,255,.65); letter-spacing: 1px; }
.site-nav .nav-link { color: rgba(255,255,255,.85); font-size: 15px; }
.site-nav .nav-link:hover, .site-nav .nav-link.active { color: #fff; font-weight: 600; }
.hotline-pill {
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.3);
  color: #fff; padding: 5px 14px; border-radius: 999px; font-size: 13px; white-space: nowrap;
}

/* 公告栏 */
.notice-bar { background: #fff8e6; border-bottom: 1px solid #fde9b8; padding: 8px 0; font-size: 13px; }
.notice-text { color: #8a6100; }

/* 轮播 */
.banner-img { width: 100%; height: 340px; object-fit: cover; display: block; }
@media (max-width: 768px) { .banner-img { height: 200px; } }

/* 分类统计 */
.cat-stats { background: #fff; border-bottom: 1px solid #e8ecf3; }
.cat-stat-item { padding: 16px 8px; cursor: pointer; transition: background .15s; border-right: 1px solid #f0f2f7; }
.cat-stat-item:hover { background: #f7f9ff; }
.cat-stat-item .cat-icon { font-size: 22px; }
.cat-stat-item .cat-cnt { display: block; font-size: 26px; font-weight: 700; color: var(--c); line-height: 1.2; }
.cat-stat-item .cat-name { display: block; font-size: 13px; color: #5b6472; }

/* 区块标题 */
.section-title h2 { font-size: 22px; font-weight: 700; color: #1c2430; position: relative; padding-left: 12px; }
.section-title h2::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 4px; border-radius: 2px; background: var(--brand); }

/* 地图布局 */
.map-section { margin-top: 26px; }
.map-layout { display: flex; gap: 14px; height: 620px; background: #fff; border-radius: 14px; box-shadow: 0 4px 24px rgba(20, 40, 90, .08); overflow: hidden; }
.map-side { width: 360px; flex: none; display: flex; flex-direction: column; border-right: 1px solid #edf0f5; }
.map-main { flex: 1; position: relative; display: block; }
/* 桌面端：两个 pane 同时显示（不走 tab） */
@media (min-width: 992px) {
  .map-side.tab-pane, .map-main.tab-pane { display: flex !important; opacity: 1 !important; }
  .map-main.tab-pane { display: block !important; }
}
#map { position: absolute; inset: 0; }

.org-list { flex: 1; overflow-y: auto; }
.org-item { padding: 12px 14px; border-bottom: 1px solid #f2f4f8; cursor: pointer; transition: background .15s; }
.org-item:hover { background: #f6f8fd; }
.org-item.active { background: #eef3ff; box-shadow: inset 3px 0 0 var(--brand); }
.org-item .oi-name { font-weight: 600; color: #1c2430; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.org-item .oi-badges { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 4px; }
.oi-badge { font-size: 11px; padding: 2px 7px; border-radius: 999px; color: #fff; }
.org-item .oi-addr { font-size: 12px; color: #7a8494; margin-top: 3px; }
.org-item .oi-addr::before { content: "📍 "; }
.org-item .oi-phone { font-size: 12px; color: #7a8494; margin-top: 3px; }
.org-item .oi-phone::before { content: "☎ "; }
.org-item .oi-tags { font-size: 12px; color: #9aa3b2; margin-top: 2px; }
.org-item .oi-btn { font-size: 12px; color: var(--brand); text-decoration: none; }
.org-item .oi-btn:hover { text-decoration: underline; }

/* 列表/弹窗 一键导航 & 一键拨号 按钮 */
.mini-act {
  flex: none; display: inline-flex; align-items: center; gap: 2px;
  font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 999px;
  text-decoration: none; transition: all .15s; white-space: nowrap;
}
.mini-nav { color: #1d4ed8; background: #e8efff; border: 1px solid #c4d6ff; }
.mini-nav:hover { background: #1d4ed8; color: #fff; }
.mini-tel { color: #15803d; background: #e9f9ef; border: 1px solid #c3ecd4; }
.mini-tel:hover { background: #16a34a; color: #fff; }
.popup-tel { font-size: 12px; color: #15803d; font-weight: 600; text-decoration: none; border-bottom: 1px dashed #86dcae; }
.popup-tel:hover { color: #16a34a; }

/* 筛选 chips */
.chip {
  border: 1px solid #dbe2ec; background: #fff; color: #52607a; font-size: 12px;
  padding: 4px 10px; border-radius: 999px; transition: all .15s;
}
.chip.active { border-color: var(--c); background: color-mix(in srgb, var(--c) 12%, #fff); color: var(--c); font-weight: 600; }

/* 地图图例 */
.map-legend {
  position: absolute; right: 12px; bottom: 24px; z-index: 500;
  background: rgba(255,255,255,.95); border-radius: 10px; padding: 10px 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,.15); font-size: 12px;
}
.map-legend .lg-row { display: flex; align-items: center; gap: 6px; padding: 2px 0; }
.map-legend .lg-dot { width: 10px; height: 10px; border-radius: 50%; }

/* 地图标注 icon */
.org-marker {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg);
  background: var(--c); border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.3);
}
.org-marker span { transform: rotate(45deg); font-size: 15px; line-height: 1; }
.leaflet-popup-content { font-size: 13px; }
.popup-title { font-weight: 700; font-size: 14px; color: #1c2430; }
.popup-row { color: #5b6472; margin: 2px 0; }

/* 新闻 */
.news-list .list-group-item { border: none; border-bottom: 1px dashed #e6e9f0; padding: 12px 8px; color: #333c4a; }
.news-list .list-group-item:hover { color: var(--brand); }
.news-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); margin-right: 10px; vertical-align: 2px; }

/* 咨询卡片 */
.consult-card { border: none; border-radius: 14px; box-shadow: 0 4px 24px rgba(20,40,90,.07); }

/* 页脚 */
.site-footer { background: #1b2436; color: #cbd4e0; }
.admin-link { font-size: 12px; color: rgba(255,255,255,.45); text-decoration: none; display: inline-block; margin-top: 6px; }
.admin-link:hover { color: #fff; }

/* 通用详情页 */
.page-wrap { background: #fff; border-radius: 14px; box-shadow: 0 4px 24px rgba(20,40,90,.07); padding: 28px; }
.breadcrumb { margin: 18px 0 0; }
.detail-title { font-size: 24px; font-weight: 700; }
.meta-line { font-size: 13px; color: #8b94a3; }
.rich-content { line-height: 1.9; color: #333c4a; }
.rich-content img { max-width: 100%; }

/* 移动端：地图/列表 tab 切换 */
@media (max-width: 991.98px) {
  /* 桌面端两个 pane 并排，移动端只显示 active 的 pane */
  .map-layout { flex-direction: column; height: auto; background: transparent; box-shadow: none; gap: 0; overflow: visible; }
  .map-side, .map-main {
    width: 100%; flex: none; border: 1px solid #e8ecf3; border-radius: 12px; background: #fff;
    box-shadow: 0 2px 12px rgba(20,40,90,.05);
    display: none;  /* tab 模式下默认都隐藏 */
  }
  .map-side.tab-pane.show.active, .map-main.tab-pane.show.active { display: flex; }
  .map-main.tab-pane.show.active { display: block; height: 70vh; min-height: 380px; }
  .map-side.tab-pane.show.active { display: flex; }
  .map-side { border-right: 1px solid #e8ecf3; border-bottom: 1px solid #edf0f5; }
  .org-list { max-height: calc(70vh - 130px); min-height: 280px; }
  .map-tab .nav-link { background: #fff; color: #475569; border: 1px solid #e2e8f0; border-radius: 8px; padding: 8px 0; font-size: 14px; font-weight: 600; }
  .map-tab .nav-link.active { background: #2563eb; color: #fff; border-color: #2563eb; }
}

/* ===== 导航栏「申请入驻」按钮 ===== */
.nav-btn-apply {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  margin-left: 6px;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  color: #fff !important;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none !important;
  text-shadow: none !important;
  border: 1.5px solid rgba(255,255,255,.25);
  box-shadow: 0 4px 12px rgba(249,115,22,.35);
  transition: transform .15s, box-shadow .15s;
  white-space: nowrap;
}
.nav-btn-apply:hover {
  color: #fff !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(249,115,22,.5);
}
.nav-btn-apply:active { transform: translateY(0); }
@media (max-width: 991px) {
  /* 移动端折叠菜单里：按钮占满一行，最显眼 */
  .nav-btn-apply { display: block; text-align: center; margin: 8px 0 4px; padding: 10px 16px; font-size: 14px; }
}
