/* Parcels overlay panel + property card (public/js/parcels.js) */

#hp-panel {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1100;
  width: 300px;
  max-width: calc(100% - 70px);
  max-height: calc(100% - 20px);
  overflow-y: auto;
  background: #fff;
  color: #222;
  border-radius: 8px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  padding: 10px 12px 12px;
  font-size: 13px;
  line-height: 1.35;
  cursor: auto;
}
#hp-panel .hp-head,
#hp-modal .hp-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
#hp-panel .hp-title { font-weight: 700; font-size: 15px; }
#hp-panel .hp-title i { color: #2e7d32; margin-right: 4px; }
.hp-x {
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #666;
  cursor: pointer;
  padding: 0 2px;
}
.hp-x:hover { color: #000; }

#hp-panel .hp-seg {
  display: flex;
  margin: 8px 0;
  background: #eee;
  border-radius: 6px;
  padding: 2px;
}
#hp-panel .hp-seg button {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 5px 4px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  cursor: pointer;
}
#hp-panel .hp-seg button.active { background: #fff; color: #111; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); }

#hp-panel .hp-search { display: flex; gap: 4px; margin-bottom: 6px; }
#hp-panel .hp-search input {
  flex: 1;
  min-width: 0;
  border: 1px solid #ccc;
  border-radius: 5px;
  padding: 4px 6px;
  font-size: 13px;
}
#hp-panel .hp-search button {
  border: 1px solid #ccc;
  background: #f6f6f6;
  border-radius: 5px;
  padding: 0 8px;
  cursor: pointer;
}

.hp-label {
  margin: 8px 0 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #777;
}
.hp-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.hp-chip {
  border: 1px solid #ccc;
  background: #fff;
  border-radius: 14px;
  padding: 2px 9px;
  font-size: 12px;
  cursor: pointer;
}
.hp-chip:hover { border-color: #2e7d32; }
.hp-chip.active { background: #2e7d32; border-color: #2e7d32; color: #fff; }

.hp-muted { color: #777; font-size: 12px; }
.hp-msg {
  margin: 6px 0;
  padding: 6px 8px;
  border-radius: 5px;
  background: #fff4e5;
  color: #8a4b00;
  font-size: 12px;
}
.hp-hint { margin-top: 8px; color: #555; font-size: 12px; }
.hp-hint i { margin-right: 4px; color: #2e7d32; }

.hp-results { margin-bottom: 6px; }
.hp-result {
  display: block;
  padding: 5px 6px;
  border-radius: 5px;
  color: #222 !important;
  text-decoration: none !important;
}
.hp-result:hover { background: #f1f7f1; }
.hp-result b { display: block; font-size: 12px; }
.hp-result span { display: block; font-size: 11px; color: #777; }

.hp-card { margin-top: 10px; padding-top: 10px; border-top: 1px solid #eee; }
.hp-card-title { font-weight: 700; font-size: 14px; }
.hp-card-sub { color: #666; font-size: 12px; }
.hp-facts { margin: 4px 0 6px; font-size: 12px; }
.hp-btn {
  display: inline-block;
  margin-top: 6px;
  border: 0;
  background: #2e7d32;
  color: #fff !important;
  border-radius: 5px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none !important;
}
.hp-btn:hover { background: #256628; }
.hp-btn.sm { margin: 0; padding: 3px 8px; }
.hp-link { display: inline-block; margin-top: 8px; font-size: 12px; }
.hp-link-btn {
  border: 0;
  background: transparent;
  padding: 0;
  color: #1a6fb5;
  font-size: 12px;
  cursor: pointer;
}
.hp-link-btn:hover { text-decoration: underline; }
.hp-link-btn + .hp-link-btn { margin-left: 12px; }

.hp-doc {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid #f0f0f0;
}
.hp-doc b { display: block; font-size: 12px; }
.hp-doc span { display: block; font-size: 11px; color: #777; word-break: break-all; }

/* property card */
#hp-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: rgba(0, 0, 0, 0.5);
  padding: 30px 12px;
  overflow-y: auto;
}
#hp-modal .hp-modal-box {
  max-width: 640px;
  margin: 0 auto;
  background: #fff;
  color: #222;
  border-radius: 10px;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.35);
  padding: 14px 16px 10px;
  font-size: 13px;
}
#hp-modal .hp-card-title { font-size: 17px; }
#hp-modal .hp-tabs {
  display: flex;
  gap: 2px;
  margin: 12px 0 10px;
  border-bottom: 1px solid #ddd;
}
#hp-modal .hp-tabs button {
  border: 0;
  background: transparent;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 600;
  color: #666;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  cursor: pointer;
}
#hp-modal .hp-tabs button.active { color: #2e7d32; border-bottom-color: #2e7d32; }
#hp-modal h6 {
  margin: 14px 0 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #777;
}
#hp-modal .hp-modal-body { min-height: 120px; }
#hp-modal .hp-modal-foot { margin-top: 12px; padding-top: 8px; border-top: 1px solid #eee; font-size: 11px; color: #888; }

.hp-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.hp-stat { background: #f5f8f5; border-radius: 6px; padding: 8px 6px; text-align: center; }
.hp-stat b { display: block; font-size: 14px; }
.hp-stat span { display: block; font-size: 11px; color: #777; }
@media (max-width: 520px) {
  .hp-stats { grid-template-columns: repeat(2, 1fr); }
}

.hp-table { width: 100%; border-collapse: collapse; }
.hp-table th,
.hp-table td { padding: 4px 6px; vertical-align: top; font-size: 12px; border-bottom: 1px solid #f0f0f0; }
.hp-table th { width: 38%; color: #666; font-weight: 600; text-align: left; }
.hp-table td { word-break: break-word; }
.hp-legal { font-size: 12px; white-space: pre-wrap; }

.hp-timeline .hp-tl-year { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f0f0f0; }
.hp-tl-y { width: 44px; font-weight: 700; flex-shrink: 0; }
.hp-tl-body { flex: 1; min-width: 0; }
.hp-match { padding: 4px 0; }
.hp-match + .hp-match { border-top: 1px dashed #eee; }
.hp-badge {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  background: #eee;
  color: #444;
}
.hp-badge.ok { background: #e3f3e4; color: #1e6b22; }
.hp-badge.warn { background: #fff1d6; color: #8a5a00; }
.hp-badge.info { background: #e1effa; color: #1a5a8f; }
.hp-badge.accent { background: #f1e6fa; color: #6a2d91; }

.hp-sale { padding: 6px 0; border-bottom: 1px solid #f0f0f0; }
