/* Housing Prices — brand #2d2e7d · fonts inherit */
.hp-app {
  --hp-brand: #2d2e7d;
  --hp-brand-2: #3f4199;
  --hp-brand-soft: #e8e9f4;
  --hp-brand-mid: #9aa0d4;
  --hp-ink: #1c1d33;
  --hp-muted: #5c5e7a;
  --hp-line: #e4e5ef;
  --hp-bg: #f3f4f8;
  --hp-card: #ffffff;
  --hp-radius: 16px;
  --hp-shadow: 0 10px 30px rgba(45, 46, 125, 0.08);
  color: var(--hp-ink);
  font: inherit;
  line-height: 1.6;
  direction: rtl;
  text-align: right;
  box-sizing: border-box;
  margin: 1.5rem 0;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: hidden;
}

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

.hp-app button,
.hp-app select {
  font: inherit;
}

.hp-shell {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 1rem;
  align-items: stretch;
  min-width: 0;
  max-width: 100%;
}

.hp-panel,
.hp-mapcol {
  background: var(--hp-card);
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
}

.hp-panel {
  padding: 1rem 1.1rem 1.15rem;
  position: sticky;
  top: 1rem;
  /* Stretch card to match map/list column; keep inner content packed at top. */
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.hp-panel__inner {
  flex: 0 0 auto;
  width: 100%;
}

.hp-mapcol {
  padding: 1rem 1rem 0.75rem;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  height: auto;
  min-width: 0;
  max-width: 100%;
  overflow-x: hidden;
}

/* Floating glass path + back-to-top (appears after scrolling past panel crumb) */
.hp-sticky-nav {
  position: fixed;
  top: 0.65rem;
  left: 50%;
  z-index: 10040;
  width: min(720px, calc(100vw - 1.25rem));
  transform: translateX(-50%) translateY(-130%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    transform 0.28s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.22s ease,
    visibility 0.22s ease;
}

.hp-sticky-nav.is-visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.hp-sticky-nav[hidden] {
  display: none !important;
}

.hp-sticky-nav__glass {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.5rem 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow:
    0 10px 28px rgba(28, 29, 51, 0.12),
    0 1px 0 rgba(255, 255, 255, 0.65) inset;
  -webkit-backdrop-filter: blur(16px) saturate(1.35);
  backdrop-filter: blur(16px) saturate(1.35);
}

.hp-sticky-nav__crumb {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-wrap: nowrap;
  gap: 0.2rem 0.35rem;
  align-items: center;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  margin: 0;
  font-size: 0.86em;
  color: var(--hp-muted);
  direction: rtl;
  unicode-bidi: isolate;
  white-space: nowrap;
}

.hp-sticky-nav__crumb::-webkit-scrollbar {
  display: none;
}

.hp-sticky-nav__crumb button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--hp-brand);
  cursor: pointer;
  font: inherit;
  white-space: nowrap;
}

.hp-sticky-nav__crumb .hp-crumb__current {
  color: var(--hp-ink);
  font-weight: 700;
  white-space: nowrap;
}

.hp-sticky-nav__actions {
  display: flex;
  flex: 0 0 auto;
  gap: 0.3rem;
  align-items: center;
}

.hp-sticky-nav__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  border: 1px solid rgba(45, 46, 125, 0.12);
  background: rgba(255, 255, 255, 0.78);
  color: var(--hp-brand);
  border-radius: 999px;
  padding: 0.38rem 0.7rem;
  font: inherit;
  font-size: 0.82em;
  font-weight: 700;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
}

.hp-sticky-nav__btn:hover {
  background: #fff;
  border-color: rgba(45, 46, 125, 0.22);
}

.hp-sticky-nav__btn.is-disabled,
.hp-sticky-nav__btn:disabled {
  opacity: 0.38;
  cursor: default;
  pointer-events: none;
}

.hp-sticky-nav__btn--back {
  background: var(--hp-brand);
  border-color: transparent;
  color: #fff;
}

.hp-sticky-nav__btn--back:hover {
  background: var(--hp-brand-2);
  border-color: transparent;
  color: #fff;
}

.hp-sticky-nav__ico {
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  flex: 0 0 auto;
}

.hp-sticky-nav__ico--back {
  border-right: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
  transform: rotate(-45deg);
  margin-inline-end: 0.05rem;
}

@media (max-width: 640px) {
  .hp-sticky-nav {
    width: calc(100vw - 0.9rem);
  }

  .hp-sticky-nav__glass {
    padding: 0.4rem 0.4rem 0.4rem 0.55rem;
    gap: 0.4rem;
  }

  .hp-sticky-nav__btn-label {
    /* Keep labels; slightly tighter */
    font-size: 0.95em;
  }
}

.hp-crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.4rem;
  align-items: center;
  margin-bottom: 0.85rem;
  font-size: 0.9em;
  color: var(--hp-muted);
  /* RTL: ایران (راست) ← فارس ← شیراز (چپ) */
  direction: rtl;
  unicode-bidi: isolate;
  justify-content: flex-start;
}

.hp-crumb a,
.hp-crumb button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--hp-brand);
  cursor: pointer;
  text-decoration: none;
  font: inherit;
}

/* Chevron: RTL path ایران ← فارس ← شیراز (points toward child) */
.hp-crumb__sep {
  display: inline-block;
  width: 0.34em;
  height: 0.34em;
  border-left: 1.6px solid currentColor;
  border-top: 1.6px solid currentColor;
  transform: rotate(-45deg);
  opacity: 0.45;
  flex: 0 0 auto;
  margin: 0 0.1rem;
}

.hp-crumb__current {
  color: var(--hp-ink);
  font-weight: 600;
}

.hp-seg {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.35rem;
  background: var(--hp-bg);
  padding: 0.3rem;
  border-radius: 999px;
  margin-bottom: 0.85rem;
}

.hp-seg__btn {
  border: 0;
  background: transparent;
  color: var(--hp-muted);
  border-radius: 999px;
  padding: 0.45rem 0.4rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.hp-seg__btn.is-active {
  background: var(--hp-brand);
  color: #fff;
  font-weight: 600;
}

.hp-kinds {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.hp-kind {
  border: 1px solid var(--hp-line);
  background: #fff;
  border-radius: 12px;
  padding: 0.45rem 0.2rem;
  cursor: pointer;
  color: var(--hp-muted);
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
  min-height: 0;
  min-width: 0;
  line-height: 1.2;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
}

.hp-kind.is-active {
  border-color: var(--hp-brand);
  color: var(--hp-brand);
  background: var(--hp-brand-soft);
}

.hp-kind__ico {
  display: block;
  width: 22px;
  height: 22px;
  margin: 0 auto 0.2rem;
  background: currentColor;
  opacity: 0.85;
  -webkit-mask: center / contain no-repeat;
  mask: center / contain no-repeat;
}

.hp-kind__ico--apt {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 21V9l8-5 8 5v12h-6v-6H10v6H4z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 21V9l8-5 8 5v12h-6v-6H10v6H4z'/%3E%3C/svg%3E");
}
.hp-kind__ico--house {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M3 11l9-8 9 8v10h-6v-6H9v6H3V11z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M3 11l9-8 9 8v10h-6v-6H9v6H3V11z'/%3E%3C/svg%3E");
}
.hp-kind__ico--land {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M3 19h18v-2L14 5 9 13 6 10 3 17v2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M3 19h18v-2L14 5 9 13 6 10 3 17v2z'/%3E%3C/svg%3E");
}
.hp-kind__ico--shop {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 6h16l-1 4H5L4 6zm1 6h14v8H5v-8z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 6h16l-1 4H5L4 6zm1 6h14v8H5v-8z'/%3E%3C/svg%3E");
}
.hp-kind__ico--office {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 3h10v18H4V3zm12 4h4v14h-4V7zM7 6h4v2H7V6zm0 4h4v2H7v-2zm0 4h4v2H7v-2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M4 3h10v18H4V3zm12 4h4v14h-4V7zM7 6h4v2H7V6zm0 4h4v2H7v-2zm0 4h4v2H7v-2z'/%3E%3C/svg%3E");
}

.hp-kind__txt {
  display: block;
  font-size: 0.72em;
  line-height: 1.2;
  text-align: center;
}

.hp-hero-price {
  margin-top: 0.1rem;
}

.hp-hero-price__head {
  margin-bottom: 0.55rem;
}

.hp-place-title {
  margin: 0 0 0.1rem;
  font-size: 1.08em;
  font-weight: 700;
  color: var(--hp-ink);
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.hp-eyebrow {
  margin: 0;
  font-size: 0.82em;
  font-weight: 500;
  color: var(--hp-muted);
  line-height: 1.45;
}

.hp-eyebrow .is-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.hp-price-block {
  position: relative;
  margin: 0 0 0.8rem;
  padding: 0.7rem 0.8rem 0.75rem;
  border-radius: 12px;
  background: linear-gradient(
    160deg,
    rgba(45, 46, 125, 0.055) 0%,
    rgba(45, 46, 125, 0.018) 50%,
    transparent 100%
  );
  border: 1px solid rgba(45, 46, 125, 0.08);
}

.hp-price-block::before {
  content: "";
  position: absolute;
  top: 0.65rem;
  bottom: 0.65rem;
  inset-inline-start: 0;
  width: 2px;
  border-radius: 2px;
  background: var(--hp-brand);
  opacity: 0.5;
}

.hp-price-line {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.45rem;
}

.hp-price-num {
  font-size: clamp(2.55rem, 5.2vw, 3.5rem);
  font-weight: 700;
  line-height: 0.95;
  color: var(--hp-brand);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.hp-price-unit {
  color: var(--hp-muted);
  font-size: 0.88em;
  font-weight: 500;
}

.hp-price-usd {
  margin: 0.4rem 0 0;
  color: var(--hp-muted);
  font-size: 0.84em;
  line-height: 1.4;
}

.hp-price-usd.is-hidden {
  display: none;
}

.hp-price-usd strong {
  color: var(--hp-ink);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.hp-list__usd,
.hp-list__gold {
  color: var(--hp-muted);
  font-size: 0.9em;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-align: left;
  min-width: 0;
}

.hp-list__gold {
  color: #8a6410;
}

.hp-compare__usd {
  display: block;
  margin-top: 0.1rem;
  color: var(--hp-muted);
  font-size: 0.78em;
}

.hp-blurb {
  margin: 0 0 0.5rem;
  color: var(--hp-muted);
  font-size: 0.9em;
  line-height: 1.65;
}

.hp-meta {
  margin: 0;
  color: var(--hp-muted);
  font-size: 0.76em;
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  line-height: 1.45;
  opacity: 0.92;
}

.hp-meta__updated time {
  font-style: normal;
}

.hp-about {
  margin-top: 0.7rem;
  border-top: 1px solid var(--hp-line);
  padding-top: 0.5rem;
}

.hp-about summary {
  cursor: pointer;
  color: var(--hp-brand);
  font-size: 0.84em;
  font-weight: 600;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  opacity: 0.9;
}

.hp-about summary:hover {
  opacity: 1;
}

.hp-about summary::-webkit-details-marker {
  display: none;
}

.hp-about__body {
  margin-top: 0.45rem;
  font-size: 0.84em;
  color: var(--hp-muted);
}

.hp-about__body p {
  margin: 0 0 0.4rem;
}

.hp-ico {
  display: inline-block;
  width: 1em;
  height: 1em;
  flex: 0 0 auto;
  background: currentColor;
  opacity: 0.85;
}

.hp-ico--info {
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='black' stroke-width='2'/%3E%3Ccircle cx='12' cy='8' r='1.2' fill='black'/%3E%3Cpath d='M12 11v6' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='black' stroke-width='2'/%3E%3Ccircle cx='12' cy='8' r='1.2' fill='black'/%3E%3Cpath d='M12 11v6' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hp-ico--sliders {
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 7h10M18 7h2M14 5v4M4 17h4M12 17h8M8 15v4M4 12h16' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 7h10M18 7h2M14 5v4M4 17h4M12 17h8M8 15v4M4 12h16' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hp-compare {
  margin-top: 0.9rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--hp-line);
}

.hp-compare__vs {
  margin: 0 0 0.55rem;
  font-size: 0.86em;
  color: var(--hp-ink);
}

.hp-linkish {
  border: 0;
  background: none;
  color: var(--hp-brand);
  cursor: pointer;
  padding: 0;
  font: inherit;
  text-decoration: underline;
}

.hp-compare__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
}

.hp-compare__card {
  border: 1px solid var(--hp-line);
  background: var(--hp-bg);
  border-radius: 12px;
  padding: 0.55rem 0.6rem;
  text-align: right;
  cursor: pointer;
  color: inherit;
  font: inherit;
}

.hp-compare__card:hover {
  border-color: var(--hp-brand);
  background: var(--hp-brand-soft);
}

.hp-compare__label {
  display: block;
  font-size: 0.72em;
  color: var(--hp-muted);
  margin-bottom: 0.2rem;
}

.hp-compare__card strong {
  display: block;
  font-size: 0.9em;
}

.hp-compare__price {
  display: block;
  margin-top: 0.15rem;
  color: var(--hp-brand);
  font-size: 0.82em;
  font-weight: 600;
}

.hp-heat {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--hp-line);
}

.hp-heat.is-hidden {
  display: none;
}

.hp-heat__head {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: baseline;
  margin-bottom: 0.55rem;
}

.hp-heat__title {
  margin: 0;
  font-size: 0.95em;
}

.hp-heat__label {
  color: var(--hp-brand);
  font-size: 0.92em;
}

.hp-heat__track {
  direction: ltr;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.45rem;
  align-items: center;
  font-size: 0.75em;
  color: var(--hp-muted);
}

.hp-heat__bar {
  position: relative;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--hp-brand), #c5c8e8 55%, #d9dbea);
}

.hp-heat__knob {
  position: absolute;
  top: 50%;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--hp-brand);
  border: 2px solid #fff;
  box-shadow: 0 1px 4px rgba(45, 46, 125, 0.35);
  transform: translate(50%, -50%);
}

.hp-heat__hint {
  margin: 0.55rem 0 0;
  font-size: 0.8em;
  color: var(--hp-muted);
}

.hp-heat__more {
  margin-top: 0.35rem;
}

.hp-heat__more summary {
  cursor: pointer;
  list-style: none;
  color: var(--hp-brand);
  font-size: 0.82em;
  font-weight: 600;
}

.hp-heat__more summary::-webkit-details-marker {
  display: none;
}

.hp-heat__more-body {
  margin-top: 0.35rem;
  font-size: 0.8em;
  color: var(--hp-muted);
}

.hp-features {
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--hp-line);
}

.hp-features summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.hp-features summary::-webkit-details-marker {
  display: none;
}

.hp-features__head {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--hp-ink);
}

.hp-features__title {
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-features__sub {
  font-size: 0.8em;
  color: var(--hp-muted);
}

.hp-features__body {
  margin-top: 0.75rem;
}

.hp-features__grid {
  display: grid;
  gap: 0.55rem;
}

.hp-feature {
  display: grid;
  gap: 0.25rem;
}

.hp-feature__label {
  font-size: 0.82em;
  color: var(--hp-muted);
}

.hp-facet {
  position: relative;
}

.hp-facet__btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  padding: 0.45rem 0.55rem;
  background: #fff;
  color: var(--hp-ink);
  font: inherit;
  text-align: right;
  cursor: pointer;
}

.hp-facet.is-open .hp-facet__btn {
  border-color: var(--hp-brand);
  box-shadow: 0 0 0 2px rgba(45, 46, 125, 0.12);
}

.hp-facet__chosen {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hp-facet__chev {
  flex: 0 0 auto;
  width: 0.45em;
  height: 0.45em;
  border-left: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  opacity: 0.45;
  margin-top: -0.15em;
  transition: transform 0.15s ease;
}

.hp-facet.is-open .hp-facet__chev {
  transform: rotate(135deg);
  margin-top: 0.15em;
}

.hp-facet__menu {
  position: absolute;
  z-index: 40;
  inset-inline: 0;
  top: calc(100% + 4px);
  margin: 0;
  padding: 0.3rem;
  list-style: none;
  background: #fff;
  border: 1px solid var(--hp-line);
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(20, 22, 60, 0.12);
  max-height: 15rem;
  overflow: auto;
}

.hp-facet__opt {
  width: 100%;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.65rem;
  border: 0;
  border-radius: 8px;
  padding: 0.42rem 0.5rem;
  background: transparent;
  color: var(--hp-ink);
  font: inherit;
  text-align: right;
  cursor: pointer;
}

.hp-facet__opt:hover,
.hp-facet__opt:focus-visible {
  background: rgba(45, 46, 125, 0.07);
  outline: none;
}

.hp-facet__opt.is-on {
  background: rgba(45, 46, 125, 0.1);
}

.hp-facet__name {
  flex: 1;
  min-width: 0;
  font-size: 0.92em;
}

.hp-facet__meta {
  display: inline-flex;
  align-items: baseline;
  gap: 0.35rem;
  flex: 0 0 auto;
  font-size: 0.62em;
  line-height: 1;
  letter-spacing: 0.01em;
  color: var(--hp-muted);
  font-variant-numeric: tabular-nums;
}

.hp-facet__avg {
  font-style: normal;
  font-weight: 700;
  color: var(--hp-brand);
  background: rgba(45, 46, 125, 0.08);
  border-radius: 999px;
  padding: 0.18em 0.45em;
}

.hp-facet__n {
  font-style: normal;
  opacity: 0.72;
  font-weight: 500;
}

.hp-features__reset {
  margin-top: 0.65rem;
  border: 0;
  background: none;
  color: var(--hp-brand);
  cursor: pointer;
  font: inherit;
  font-size: 0.86em;
  padding: 0;
}

.hp-features__empty {
  margin: 0;
  font-size: 0.85em;
  color: var(--hp-muted);
}

@media (max-width: 560px) {
  .hp-compare__grid {
    grid-template-columns: 1fr;
  }
}

.hp-map-heading-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin: 0 0 0.65rem;
  position: relative;
  z-index: 6;
}

.hp-map-heading {
  margin: 0;
  font-size: 1.05em;
  font-weight: 600;
}

.hp-map-heading-row .hp-chart-help.is-open,
.hp-map-heading-row .hp-chart-help:hover,
.hp-map-heading-row .hp-chart-help:focus-within {
  z-index: 70;
}

.hp-legend {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.45rem;
  align-items: center;
  margin: 0 0 0.85rem;
  font-size: 0.78em;
  color: var(--hp-muted);
  line-height: 1.3;
}

.hp-legend__bar {
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(to left, var(--hp-brand-soft), var(--hp-brand-mid), var(--hp-brand));
  min-width: 0;
}

.hp-legend__min,
.hp-legend__max {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  color: var(--hp-ink);
  font-weight: 600;
}

.hp-legend__unit {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 0.92em;
  margin-top: -0.15rem;
}

.hp-map-frame {
  position: relative;
  background: linear-gradient(180deg, #f7f8fc 0%, #eef0f8 100%);
  border: 1px solid var(--hp-line);
  border-radius: 14px;
  padding: 0.5rem;
  min-height: 320px;
}

.hp-map-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  touch-action: manipulation;
  cursor: default;
  user-select: none;
  -webkit-user-select: none;
}

.hp-map-viewport--pannable {
  touch-action: none;
  cursor: grab;
}

.hp-map-viewport.is-panning {
  cursor: grabbing;
}

.hp-map {
  width: 100%;
  height: auto;
  max-height: 520px;
  display: block;
  pointer-events: auto;
}

.hp-zoom {
  position: absolute;
  z-index: 3;
  left: 0.55rem;
  top: 0.55rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.hp-zoom__btn {
  width: 36px;
  height: 36px;
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--hp-brand);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(45, 46, 125, 0.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.hp-zoom__btn:hover {
  background: var(--hp-brand);
  color: #fff;
  border-color: var(--hp-brand);
}

.hp-zoom__btn:active {
  transform: scale(0.96);
}

.hp-zoom__btn--locate {
  margin-top: 0.25rem;
  color: #fff;
  background: var(--hp-brand);
  border-color: var(--hp-brand);
}

.hp-zoom__btn--locate:hover {
  background: var(--hp-brand-2);
  border-color: var(--hp-brand-2);
  color: #fff;
}

.hp-zoom__btn--locate .hp-ico--locate {
  width: 1.05em;
  height: 1.05em;
  background: currentColor;
  opacity: 1;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='3' fill='black'/%3E%3Cpath d='M12 2v3M12 19v3M2 12h3M19 12h3' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='12' cy='12' r='8' fill='none' stroke='black' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='3' fill='black'/%3E%3Cpath d='M12 2v3M12 19v3M2 12h3M19 12h3' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='12' cy='12' r='8' fill='none' stroke='black' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hp-zoom__btn--locate.is-busy {
  opacity: 0.7;
  pointer-events: none;
  animation: hp-pulse 1.1s ease-in-out infinite;
}

@keyframes hp-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(0.94);
  }
}

.hp-map__user {
  pointer-events: none;
}

.hp-map__user-pulse {
  fill: rgba(45, 46, 125, 0.22);
  stroke: none;
}

.hp-map__user-dot {
  fill: var(--hp-brand);
  stroke: #fff;
  stroke-width: 2;
}

.hp-map__poly {
  fill: var(--hp-brand-soft);
  stroke: #fff;
  stroke-width: 1.1;
  stroke-linejoin: round;
  stroke-linecap: round;
  cursor: pointer;
  transition: fill 0.15s ease;
}

.hp-map__labels {
  pointer-events: none;
  display: none;
}

.hp-map-labels-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}

.hp-map-labels-overlay.is-hidden {
  display: none;
}

.hp-map-label {
  position: absolute;
  transform: translate(-50%, -50%);
  color: #1c1d33;
  font-weight: 600;
  line-height: 1.1;
  white-space: nowrap;
  max-width: 9em;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow:
    0 0 2px #fff,
    0 0 3px #fff,
    1px 0 0 #fff,
    -1px 0 0 #fff,
    0 1px 0 #fff,
    0 -1px 0 #fff;
  pointer-events: none;
}

.hp-map-frame:not(.is-big) .hp-map-labels-overlay {
  display: none !important;
}

/* Hover: فقط کمی روشن/تیره شدن پررنگ — بدون بوردر */
.hp-map__poly:hover,
.hp-map__poly.is-hover {
  filter: brightness(0.94);
}

/* بوردر فقط بعد از کلیک / انتخاب */
.hp-map__poly.is-active {
  stroke: var(--hp-brand);
  stroke-width: 2.8;
  stroke-linejoin: round;
  filter: none;
}

.hp-app--city-map .hp-map__poly {
  stroke-width: 0.6;
}

.hp-app--city-map .hp-map__poly.is-active {
  stroke-width: 2.2;
  stroke: #12133f;
}

.hp-map-note {
  margin: 0 0 0.45rem;
  font-size: 0.85em;
  color: var(--hp-brand);
  font-weight: 600;
}

.hp-map-note.is-hidden {
  display: none;
}

.hp-list__item.is-active .hp-list__btn {
  background: var(--hp-brand-soft);
}

.hp-list__item.is-active .hp-list__name {
  font-weight: 600;
  color: var(--hp-brand);
}

.hp-map-tip {
  position: absolute;
  z-index: 2;
  background: rgba(28, 29, 51, 0.92);
  color: #fff;
  padding: 0.4rem 0.65rem;
  border-radius: 8px;
  font-size: 0.82em;
  pointer-events: none;
  transform: translate(-50%, -120%);
  white-space: nowrap;
}

.hp-map-tip.is-hidden {
  display: none;
}

.hp-map-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.55rem 0 0.15rem;
  flex-wrap: wrap;
}

.hp-map-status {
  margin: 0;
  color: var(--hp-muted);
  font-size: 0.85em;
  flex: 1 1 auto;
  min-width: 12rem;
}

.hp-bigmap-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid #2a2b3d;
  background: #fff;
  color: var(--hp-ink);
  border-radius: 10px;
  padding: 0.38rem 0.7rem;
  font: inherit;
  font-size: 0.86em;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.hp-bigmap-btn:hover {
  border-color: var(--hp-brand);
  color: var(--hp-brand);
}

.hp-ico--expand {
  width: 0.95em;
  height: 0.95em;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 3H3v5M16 3h5v5M8 21H3v-5M16 21h5v-5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 3H3v5M16 3h5v5M8 21H3v-5M16 21h5v-5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hp-bigmap-bar {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.55rem;
  flex-wrap: wrap;
}

.hp-bigmap-bar.is-hidden {
  display: none;
}

.hp-bigmap-close {
  width: 40px;
  height: 40px;
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  background: #fff;
  color: var(--hp-ink);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  flex: 0 0 auto;
}

.hp-bigmap-close:hover {
  border-color: var(--hp-brand);
  color: var(--hp-brand);
}

.hp-bigmap-search {
  position: relative;
  flex: 1 1 220px;
  max-width: 420px;
}

.hp-bigmap-input {
  width: 100%;
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  padding: 0.55rem 0.75rem;
  background: #fff;
  color: var(--hp-ink);
  font: inherit;
}

.hp-bigmap-input:focus {
  outline: 2px solid var(--hp-brand-soft);
  border-color: var(--hp-brand);
}

.hp-bigmap-results {
  position: absolute;
  z-index: 8;
  top: calc(100% + 4px);
  right: 0;
  left: 0;
  margin: 0;
  padding: 0.3rem;
  list-style: none;
  background: #fff;
  border: 1px solid var(--hp-line);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(28, 29, 51, 0.14);
  max-height: 280px;
  overflow: auto;
}

.hp-bigmap-results.is-hidden {
  display: none;
}

.hp-bigmap-results li {
  margin: 0;
}

.hp-bigmap-results button {
  width: 100%;
  border: 0;
  background: transparent;
  text-align: right;
  padding: 0.5rem 0.6rem;
  border-radius: 8px;
  cursor: pointer;
  color: inherit;
  font: inherit;
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
}

.hp-bigmap-results button:hover,
.hp-bigmap-results button.is-active {
  background: var(--hp-brand-soft);
}

.hp-bigmap-results__price {
  color: var(--hp-brand);
  font-weight: 600;
  white-space: nowrap;
}

.hp-bigmap-results__empty {
  padding: 0.55rem 0.65rem;
  color: var(--hp-muted);
  font-size: 0.9em;
}

.hp-bigmap-title {
  margin: 0;
  margin-right: auto;
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-map-frame.is-big {
  position: fixed;
  inset: 0;
  z-index: 100000;
  border-radius: 0;
  border: 0;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 0.75rem 1rem 1rem;
  background: #f7f8fc;
  display: flex;
  flex-direction: column;
  box-shadow: none;
}

.hp-map-frame.is-big .hp-map-viewport {
  flex: 1 1 auto;
  min-height: 0;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--hp-line);
}

.hp-map-frame.is-big .hp-map {
  max-height: none;
  height: 100%;
  width: 100%;
}

.hp-map-frame.is-big .hp-map-foot {
  margin-top: 0.65rem;
}

.hp-map-frame.is-big .hp-bigmap-btn {
  display: none;
}

body.hp-bigmap-open {
  overflow: hidden;
}

.hp-map-heading-row,
.hp-map-heading,
.hp-legend,
.hp-map-frame {
  flex: 0 0 auto;
}

.hp-list-wrap {
  margin-top: 0.85rem;
  border-top: 1px solid var(--hp-line);
  padding-top: 0.75rem;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
}

.hp-list-xscroll {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.hp-list-xscroll__inner {
  width: 100%;
  min-width: 0;
}

.hp-list-head {
  display: flex;
  justify-content: space-between;
  gap: 0.55rem 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 0.45rem;
  flex: 0 0 auto;
}

.hp-list-title {
  margin: 0;
  flex: 1 1 100%;
  font-size: 1.02em;
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-list-tabs.is-hidden,
.hp-list-title.is-hidden {
  display: none !important;
}

/* Segmented control — scoped under .hp-app to beat theme button resets */
.hp-app .hp-list-tabs {
  display: inline-flex;
  align-items: stretch;
  flex-wrap: nowrap;
  gap: 0;
  min-width: 0;
  max-width: 100%;
  padding: 3px;
  border-radius: 10px;
  background: var(--hp-brand-soft);
  border: 1px solid rgba(45, 46, 125, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.hp-app .hp-list-tabs__btn {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  padding: 0.42rem 0.85rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--hp-muted);
  font: inherit;
  font-size: 0.84em;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: none;
  text-shadow: none;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.hp-app .hp-list-tabs__btn:hover,
.hp-app .hp-list-tabs__btn:focus {
  color: var(--hp-brand);
  background: rgba(255, 255, 255, 0.45);
  outline: none;
}

.hp-app .hp-list-tabs__btn:focus-visible {
  outline: 2px solid rgba(45, 46, 125, 0.35);
  outline-offset: 1px;
}

.hp-app .hp-list-tabs__btn.is-active,
.hp-app .hp-list-tabs__btn.is-active:hover {
  background: #fff;
  color: var(--hp-brand);
  box-shadow: 0 1px 2px rgba(45, 46, 125, 0.12), 0 0 0 1px rgba(45, 46, 125, 0.06);
}

@media (max-width: 520px) {
  .hp-app .hp-list-tabs {
    width: 100%;
  }

  .hp-app .hp-list-tabs__btn {
    flex: 1 1 0;
    padding-inline: 0.55rem;
    font-size: 0.78em;
    text-align: center;
    white-space: normal;
  }
}

.hp-list-cols {
  display: grid;
  /* Name stays readable on one line; numbers share the rest evenly */
  grid-template-columns: 10px minmax(5.5rem, 7rem) minmax(3.4rem, 1fr) minmax(3.4rem, 1fr) minmax(3.6rem, 1fr);
  gap: 0.4rem 0.5rem;
  align-items: end;
  padding: 0 0.3rem 0.4rem;
  margin-bottom: 0.15rem;
  border-bottom: 1px solid var(--hp-line);
  color: var(--hp-muted);
  font-size: 0.76em;
  font-weight: 700;
  flex: 0 0 auto;
  line-height: 1.25;
}

.hp-list-cols__usd,
.hp-list-cols__gold,
.hp-list-cols__price {
  text-align: left;
  white-space: normal;
}

.hp-list-cols small {
  display: block;
  margin-top: 0.12rem;
  font-size: 0.86em;
  font-weight: 500;
  color: var(--hp-muted);
  opacity: 0.9;
}

.hp-sort select {
  border: 1px solid var(--hp-line);
  border-radius: 8px;
  padding: 0.3rem 0.5rem;
  background: #fff;
  color: var(--hp-ink);
}

.hp-list {
  list-style: none;
  margin: 0;
  padding: 0;
  /* At least ~10 rows; JS may grow it to align with panel content, then scroll. */
  min-height: calc(10 * 2.9rem);
  height: calc(10 * 2.9rem);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.hp-list__btn {
  width: 100%;
  display: grid;
  grid-template-columns: 10px minmax(5.5rem, 7rem) minmax(3.4rem, 1fr) minmax(3.4rem, 1fr) minmax(3.6rem, 1fr);
  gap: 0.4rem 0.5rem;
  align-items: center;
  border: 0;
  background: transparent;
  padding: 0.55rem 0.3rem;
  border-bottom: 1px solid var(--hp-line);
  cursor: pointer;
  color: inherit;
  text-align: right;
}

.hp-list__btn:hover {
  background: var(--hp-brand-soft);
}

.hp-list__swatch {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  background: var(--hp-brand-mid);
}

.hp-list__name {
  overflow: hidden;
  white-space: normal;
  overflow-wrap: normal;
  word-break: keep-all;
  line-height: 1.3;
  max-width: 100%;
  hyphens: none;
}

.hp-list__price {
  text-align: left;
  white-space: nowrap;
  min-width: 0;
}

.hp-list__price strong {
  color: var(--hp-brand);
  font-variant-numeric: tabular-nums;
}

.hp-list__item.is-muted .hp-list__price strong,
.hp-list__item.is-muted .hp-list__usd,
.hp-list__item.is-muted .hp-list__gold {
  color: var(--hp-muted);
  font-weight: 500;
}

.hp-error {
  padding: 1rem;
  border: 1px solid #f0c2c2;
  background: #fff5f5;
  border-radius: 12px;
}

.hp-noscript {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px dashed var(--hp-line);
  border-radius: 12px;
}

.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hp-app.is-loading .hp-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.45);
  border-radius: inherit;
  pointer-events: none;
}

@media (max-width: 960px) {
  .hp-shell {
    grid-template-columns: 1fr;
  }
  .hp-panel {
    position: static;
    order: 1;
    align-self: stretch;
    padding: 0.85rem 0.9rem 1rem;
    min-width: 0;
    max-width: 100%;
  }
  .hp-mapcol {
    order: 2;
    height: auto;
    min-height: 0;
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }

  .hp-kinds {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .hp-kind {
    padding: 0.4rem 0.15rem;
  }

  .hp-kind__ico {
    width: 18px;
    height: 18px;
  }

  .hp-kind__txt {
    font-size: 0.64em;
  }

  /* Fit all 4 columns in the card; soft overflow only if viewport is tiny */
  .hp-list-xscroll {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }

  .hp-list-xscroll__inner {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .hp-list-xscroll .hp-list-cols,
  .hp-list-xscroll .hp-list {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .hp-list-xscroll .hp-list-cols,
  .hp-list-xscroll .hp-list__btn {
    /* One-line names (ellipsis); keep all 4 value cols in view */
    grid-template-columns: 9px minmax(0, 5.4rem) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.3rem 0.35rem;
    padding-left: 0.15rem;
    padding-right: 0.25rem;
  }

  .hp-list-xscroll .hp-list-cols {
    font-size: 0.7em;
  }

  .hp-list-xscroll .hp-list__name {
    font-size: 0.92em;
    font-weight: 600;
  }

  .hp-list-xscroll .hp-list__usd,
  .hp-list-xscroll .hp-list__gold,
  .hp-list-xscroll .hp-list__price {
    font-size: 0.9em;
  }

  .hp-list-xscroll .hp-list__btn {
    padding-top: 0.52rem;
    padding-bottom: 0.52rem;
  }

  .hp-list {
    min-height: calc(8 * 2.9rem);
    height: calc(8 * 2.9rem);
    overflow-x: hidden;
    overflow-y: auto;
  }
}

@media (max-width: 560px) {
  .hp-map-frame {
    min-height: 260px;
  }
  .hp-list-xscroll .hp-list-cols,
  .hp-list-xscroll .hp-list__btn {
    grid-template-columns: 9px minmax(0, 5.1rem) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.28rem 0.32rem;
  }
  .hp-list {
    min-height: calc(8 * 2.75rem);
    height: calc(8 * 2.75rem);
  }
}

/* —— Top spotlight: stats + major cities —— */
.hp-top {
  display: grid;
  gap: 1rem;
  padding: 1.15rem 1.2rem 1.25rem;
  background:
    linear-gradient(145deg, rgba(45, 46, 125, 0.07) 0%, rgba(45, 46, 125, 0.02) 42%, #fff 100%),
    var(--hp-card);
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
  overflow: visible;
}

.hp-top__eyebrow {
  margin: 0 0 0.2rem;
  font-size: 0.78em;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--hp-brand);
}

.hp-top__title {
  margin: 0 0 0.35rem;
  font-size: clamp(1.15rem, 2.4vw, 1.45rem);
  font-weight: 700;
  color: var(--hp-ink);
  line-height: 1.35;
}

.hp-top__lead {
  margin: 0;
  max-width: 46rem;
  color: var(--hp-muted);
  font-size: 0.9em;
  line-height: 1.65;
}

.hp-analyst {
  display: grid;
  gap: 0.65rem;
  overflow: visible;
}

.hp-rates {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.4rem;
}

.hp-rates__chip {
  margin: 0;
  padding: 0.4rem 0.6rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(45, 46, 125, 0.1);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.15rem 0.4rem;
  min-width: 0;
  line-height: 1.25;
}

.hp-rates__chip--tala18,
.hp-rates__chip--seke {
  background: linear-gradient(180deg, #fffdf7, #fff8ea);
  border-color: rgba(184, 134, 45, 0.28);
}

.hp-rates__label {
  flex: 1 1 auto;
  font-size: 0.7em;
  font-weight: 600;
  color: var(--hp-muted);
  white-space: nowrap;
}

.hp-rates__chip--country .hp-rates__label,
.hp-rates__chip--centers .hp-rates__label {
  white-space: normal;
}

.hp-rates__value {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--hp-brand);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.hp-rates__chip--tala18 .hp-rates__value,
.hp-rates__chip--seke .hp-rates__value {
  color: #8a6410;
}

.hp-rates__unit {
  font-size: 0.68em;
  color: var(--hp-muted);
  white-space: nowrap;
}

.hp-rates__chg {
  font-size: 0.68em;
  font-weight: 700;
  margin-inline-start: auto;
}

.hp-rates__chg.is-up {
  color: #0f7a4c;
}

.hp-rates__chg.is-down {
  color: #b42318;
}

.hp-analyst__headline {
  margin: 0;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  background: linear-gradient(105deg, rgba(45, 46, 125, 0.1), rgba(45, 46, 125, 0.03));
  border: 1px solid rgba(45, 46, 125, 0.1);
  color: var(--hp-ink);
  font-size: 0.86em;
  font-weight: 650;
  line-height: 1.55;
}

.hp-insights {
  display: grid;
  grid-template-columns: 1.35fr repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  align-items: start;
  grid-auto-rows: auto;
  overflow: visible;
}

.hp-insight {
  --hp-insight-pad: 0.85rem 0.9rem;
  --hp-insight-pad-x: 0.9rem;
  margin: 0;
  padding: 0;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--hp-line);
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  position: relative;
  overflow: hidden;
  z-index: 1;
  transition:
    border-color 0.32s ease,
    box-shadow 0.32s ease,
    border-radius 0.32s ease,
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.hp-insight.has-more {
  cursor: pointer;
}

.hp-insight__face {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1 1 auto;
  padding: var(--hp-insight-pad);
  min-width: 0;
  position: relative;
  z-index: 1;
}

.hp-insight__hint {
  display: none;
}

/* —— 6 tile cards: expand details —— */
.hp-insight:not(.is-featured) {
  height: auto;
  align-self: start;
}

.hp-insight:not(.is-featured).has-more {
  overflow: hidden;
}

.hp-insight:not(.is-featured) .hp-insight__more {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  max-height: 0;
  padding: 0 var(--hp-insight-pad-x);
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  background: transparent;
  border: 0;
  border-top: 1px solid transparent;
  box-shadow: none;
  transition:
    max-height 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.28s ease,
    padding 0.32s ease,
    border-color 0.28s ease;
}

.hp-insight:not(.is-featured) .hp-insight__more-title {
  display: none;
}

/* Click / keyboard — single source of truth on touch devices */
.hp-insight:not(.is-featured).has-more.is-open,
.hp-insight:not(.is-featured).has-more:focus-visible {
  z-index: 40;
  border-color: rgba(45, 46, 125, 0.34);
  box-shadow: 0 14px 32px rgba(45, 46, 125, 0.14);
  outline: none;
}

.hp-insight:not(.is-featured).has-more.is-open .hp-insight__more,
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__more {
  max-height: 20rem;
  opacity: 1;
  pointer-events: auto;
  padding: 0.35rem var(--hp-insight-pad-x) 0.9rem;
  border-top-color: rgba(45, 46, 125, 0.14);
}

.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact,
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact {
  animation: hpInsightFactIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact:nth-child(1),
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact:nth-child(1) {
  animation-delay: 0.04s;
}
.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact:nth-child(2),
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact:nth-child(2) {
  animation-delay: 0.08s;
}
.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact:nth-child(3),
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact:nth-child(3) {
  animation-delay: 0.12s;
}
.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact:nth-child(4),
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact:nth-child(4) {
  animation-delay: 0.16s;
}
.hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact:nth-child(n + 5),
.hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact:nth-child(n + 5) {
  animation-delay: 0.2s;
}

@keyframes hpInsightFactIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* Desktop only: hover expands (avoids sticky-hover bug on phones) */
@media (hover: hover) and (pointer: fine) {
  .hp-insight:not(.is-featured).has-more {
    overflow: visible;
  }

  .hp-insight:not(.is-featured) .hp-insight__more {
    position: absolute;
    top: calc(100% - 1px);
    inset-inline: -1px;
    z-index: 3;
    background: #fff;
    border: 1px solid transparent;
    border-top: 1px dashed rgba(45, 46, 125, 0.14);
    border-radius: 0 0 14px 14px;
    transition:
      max-height 0.48s cubic-bezier(0.22, 1, 0.36, 1),
      opacity 0.28s ease,
      padding 0.36s ease,
      border-color 0.28s ease,
      box-shadow 0.36s ease;
  }

  .hp-insight:not(.is-featured).has-more:hover {
    z-index: 40;
    border-color: rgba(45, 46, 125, 0.34);
    border-end-start-radius: 0;
    border-end-end-radius: 0;
    box-shadow: 0 10px 28px rgba(45, 46, 125, 0.12);
    transform: translateY(-3px);
  }

  .hp-insight:not(.is-featured).has-more:hover .hp-insight__more {
    max-height: 18rem;
    opacity: 1;
    pointer-events: auto;
    padding: 0.55rem var(--hp-insight-pad-x) 0.85rem;
    border-color: rgba(45, 46, 125, 0.34);
    box-shadow:
      0 18px 36px rgba(45, 46, 125, 0.14),
      0 1px 0 rgba(255, 255, 255, 0.8) inset;
  }

  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact {
    animation: hpInsightFactIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
  }
  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact:nth-child(1) {
    animation-delay: 0.04s;
  }
  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact:nth-child(2) {
    animation-delay: 0.09s;
  }
  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact:nth-child(3) {
    animation-delay: 0.14s;
  }
  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact:nth-child(4) {
    animation-delay: 0.19s;
  }
  .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact:nth-child(n + 5) {
    animation-delay: 0.24s;
  }

  /* Desktop click-open: same hanging panel as hover */
  .hp-insight:not(.is-featured).has-more.is-open,
  .hp-insight:not(.is-featured).has-more:focus-visible {
    border-end-start-radius: 0;
    border-end-end-radius: 0;
    transform: translateY(-3px);
  }

  .hp-insight:not(.is-featured).has-more.is-open .hp-insight__more,
  .hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__more {
    padding: 0.55rem var(--hp-insight-pad-x) 0.85rem;
    border-color: rgba(45, 46, 125, 0.34);
    background: #fff;
    box-shadow:
      0 18px 36px rgba(45, 46, 125, 0.14),
      0 1px 0 rgba(255, 255, 255, 0.8) inset;
  }
}

/* Featured gold: keep in-place overlay (not the expand tiles) */
.hp-insight.is-featured .hp-insight__more {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: var(--hp-insight-pad);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(45, 46, 125, 0.07), transparent 55%),
    linear-gradient(165deg, #ffffff 0%, #f7f8ff 100%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.28s ease, visibility 0.28s ease;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.hp-insight.is-featured.has-more:focus-visible .hp-insight__face,
.hp-insight.is-featured.is-open .hp-insight__face {
  opacity: 0;
  pointer-events: none;
}

.hp-insight.is-featured.has-more:focus-visible .hp-insight__more,
.hp-insight.is-featured.is-open .hp-insight__more {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.hp-insight__more-title {
  margin: 0;
  font-size: 0.74em;
  font-weight: 750;
  color: var(--hp-brand);
}

.hp-insight__facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.3rem;
}

.hp-insight__fact {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.65rem;
  margin: 0;
  padding: 0.25rem 0;
  border-bottom: 1px dashed rgba(45, 46, 125, 0.12);
  font-size: 0.76em;
  line-height: 1.4;
}

.hp-insight__fact:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.hp-insight__fact > span {
  color: var(--hp-muted);
  flex: 1 1 auto;
  min-width: 0;
}

.hp-insight__fact > strong {
  color: var(--hp-ink);
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  text-align: left;
  white-space: nowrap;
  max-width: 58%;
}

.hp-insight__fact--story {
  display: block;
  margin-top: 0.1rem;
  padding: 0.4rem 0.5rem;
  border: 0;
  border-radius: 10px;
  background: rgba(45, 46, 125, 0.05);
  color: var(--hp-ink);
  font-size: 0.74em;
  line-height: 1.5;
  font-weight: 550;
}

.hp-insight.is-featured {
  --hp-insight-pad: 1.15rem 1.15rem 1.2rem;
  grid-row: span 2;
  align-self: stretch;
  height: 100%;
  min-height: 100%;
  border-color: rgba(184, 134, 45, 0.38);
  background:
    radial-gradient(90% 70% at 0% 100%, rgba(212, 168, 75, 0.16), transparent 55%),
    radial-gradient(120% 90% at 100% 0%, rgba(245, 200, 90, 0.28), transparent 52%),
    linear-gradient(165deg, #fffef9 0%, #fff7e6 48%, #fff3d6 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.75) inset,
    0 10px 28px rgba(138, 100, 16, 0.1);
  transition: border-color 0.28s ease, box-shadow 0.28s ease;
}

.hp-insight.is-featured .hp-insight__face {
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
  padding-inline-start: 1.25rem;
  gap: 0.35rem;
}

.hp-insight.is-featured .hp-insight__more {
  position: absolute;
  padding-inline-start: 1.25rem;
  background:
    radial-gradient(90% 70% at 0% 100%, rgba(212, 168, 75, 0.18), transparent 55%),
    radial-gradient(120% 90% at 100% 0%, rgba(245, 200, 90, 0.32), transparent 52%),
    linear-gradient(165deg, #fffef9 0%, #fff7e6 48%, #fff3d6 100%);
}

.hp-insight.is-featured.has-more:focus-visible,
.hp-insight.is-featured.is-open {
  border-color: rgba(184, 134, 45, 0.5);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.8) inset,
    0 14px 30px rgba(138, 100, 16, 0.14);
}

.hp-insight.is-featured .hp-insight__more-title {
  color: #6e4f0c;
}

.hp-insight.is-featured .hp-insight__fact {
  border-bottom-color: rgba(184, 134, 45, 0.22);
}

.hp-insight.is-featured .hp-insight__fact > strong {
  color: #8a6410;
}

.hp-insight.is-featured .hp-insight__fact--story {
  background: rgba(184, 134, 45, 0.12);
  color: #5c4a22;
}

.hp-insight.is-featured::before {
  content: "";
  position: absolute;
  inset-inline-end: -18%;
  top: -12%;
  width: 9.5rem;
  height: 9.5rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 35%, rgba(255, 236, 180, 0.95), rgba(212, 168, 75, 0.22) 42%, transparent 68%);
  pointer-events: none;
  z-index: 0;
}

.hp-insight.is-featured::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 0.85rem;
  bottom: 0.85rem;
  width: 3px;
  border-radius: 999px;
  background: linear-gradient(180deg, #f0c14b, #b8862d 55%, #8a6410);
  z-index: 1;
}

.hp-insight.is-featured .hp-insight__badge {
  position: relative;
  z-index: 1;
}

.hp-insight__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  width: fit-content;
  margin: 0 0 0.15rem;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  font-size: 0.68em;
  font-weight: 750;
  letter-spacing: 0.01em;
  color: #6e4f0c;
  background: linear-gradient(180deg, #fff6d8, #f3dfa0);
  border: 1px solid rgba(184, 134, 45, 0.35);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) inset;
}

.hp-insight__badge::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 2px;
  background: linear-gradient(145deg, #f5d67a, #b8862d);
  box-shadow: 0 0 0 1px rgba(138, 100, 16, 0.2);
}

.hp-insight--gold {
  border-color: rgba(184, 134, 45, 0.22);
}

.hp-insight--accent {
  /* Keep parity with other tiles — no one-off thick brand edge */
  border-inline-start-color: var(--hp-line);
  border-inline-start-width: 1px;
}

.hp-insight__eye {
  margin: 0;
  font-size: 0.74em;
  font-weight: 600;
  color: var(--hp-muted);
}

.hp-insight.is-featured .hp-insight__eye {
  font-size: 0.82em;
  font-weight: 750;
  color: #6e4f0c;
}

.hp-insight__value {
  margin: 0;
  font-size: clamp(1.15rem, 2.2vw, 1.55rem);
  font-weight: 800;
  color: var(--hp-brand);
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

.hp-insight.is-featured .hp-insight__value,
.hp-insight--gold .hp-insight__value {
  color: #8a6410;
}

.hp-insight.is-featured .hp-insight__value {
  margin-top: 0.15rem;
  font-size: clamp(2rem, 3.4vw, 2.65rem);
  font-weight: 850;
  letter-spacing: -0.02em;
  line-height: 1.05;
  background: linear-gradient(180deg, #c4961f 0%, #8a6410 70%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

@supports not ((-webkit-background-clip: text) or (background-clip: text)) {
  .hp-insight.is-featured .hp-insight__value {
    color: #8a6410;
    background: none;
  }
}

.hp-insight__unit {
  margin: 0;
  font-size: 0.82em;
  font-weight: 650;
  color: var(--hp-ink);
  line-height: 1.35;
}

.hp-insight.is-featured .hp-insight__unit {
  font-size: 0.9em;
  font-weight: 700;
  color: #5c4a22;
}

.hp-insight__note {
  margin: 0.15rem 0 0;
  font-size: 0.76em;
  color: var(--hp-muted);
  line-height: 1.45;
}

.hp-insight.is-featured .hp-insight__note {
  margin-top: auto;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(184, 134, 45, 0.22);
  font-size: 0.8em;
  color: #7a6840;
  line-height: 1.5;
}

.hp-stats {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.65rem;
}

.hp-stats__item {
  padding: 0.65rem 0.7rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(45, 46, 125, 0.08);
  display: grid;
  gap: 0.15rem;
  min-width: 0;
}

.hp-stats__label {
  font-size: 0.72em;
  color: var(--hp-muted);
}

.hp-stats__value {
  font-size: 1.02em;
  font-weight: 700;
  color: var(--hp-brand);
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hp-stats__sub {
  font-size: 0.72em;
  color: var(--hp-muted);
  line-height: 1.35;
}

.hp-cities__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 1rem;
  margin-bottom: 0.65rem;
}

.hp-cities__title {
  margin: 0;
  font-size: 1.02em;
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-cities__sub {
  margin: 0;
  font-size: 0.8em;
  color: var(--hp-muted);
}

.hp-cities__grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.65rem;
}

.hp-city {
  --hp-city-pad: 0.75rem 0.8rem 0.8rem;
  margin: 0;
  padding: 0;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--hp-line);
  border-inline-start: 3px solid var(--hp-brand);
  min-width: 0;
  display: grid;
  text-align: right;
  font: inherit;
  color: inherit;
  cursor: pointer;
  width: 100%;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease, background 0.28s ease;
}

.hp-city:focus-visible,
.hp-city.is-open {
  border-color: rgba(45, 46, 125, 0.35);
  background: rgba(45, 46, 125, 0.03);
  box-shadow: 0 10px 24px rgba(45, 46, 125, 0.08);
  transform: translateY(-1px);
  outline: none;
}

.hp-city__face {
  display: grid;
  gap: 0.3rem;
  padding: var(--hp-city-pad);
  min-width: 0;
  transition: opacity 0.28s ease, transform 0.28s ease, filter 0.28s ease;
}

.hp-city.has-more:focus-visible .hp-city__face,
.hp-city.is-open .hp-city__face {
  opacity: 0;
  transform: translateY(-8px) scale(0.98);
  filter: blur(1.5px);
  pointer-events: none;
}

.hp-city__hint {
  display: inline-flex;
  align-items: center;
  gap: 0.22rem;
  margin-top: 0.2rem;
  width: fit-content;
  padding: 0.1rem 0.38rem;
  border-radius: 999px;
  font-size: 0.64em;
  font-weight: 700;
  color: var(--hp-brand);
  background: rgba(45, 46, 125, 0.06);
  border: 1px solid rgba(45, 46, 125, 0.1);
}

.hp-city__hint::after {
  content: "";
  width: 0.32rem;
  height: 0.32rem;
  border-inline-end: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  margin-top: -0.08rem;
}

.hp-city__more {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: var(--hp-city-pad);
  background:
    radial-gradient(120% 90% at 0% 0%, rgba(45, 46, 125, 0.08), transparent 55%),
    linear-gradient(165deg, #ffffff 0%, #f6f7fd 100%);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  text-align: right;
}

.hp-city.has-more:focus-visible .hp-city__more,
.hp-city.is-open .hp-city__more {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (hover: hover) and (pointer: fine) {
  .hp-insight.is-featured.has-more:hover {
    border-color: rgba(184, 134, 45, 0.5);
    box-shadow:
      0 1px 0 rgba(255, 255, 255, 0.8) inset,
      0 14px 30px rgba(138, 100, 16, 0.14);
  }
  .hp-insight.is-featured.has-more:hover .hp-insight__face {
    opacity: 0;
    pointer-events: none;
  }
  .hp-insight.is-featured.has-more:hover .hp-insight__more {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
  .hp-city.has-more:hover {
    border-color: rgba(45, 46, 125, 0.35);
    background: rgba(45, 46, 125, 0.03);
    box-shadow: 0 10px 24px rgba(45, 46, 125, 0.08);
    transform: translateY(-1px);
  }
  .hp-city.has-more:hover .hp-city__face {
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
    filter: blur(1.5px);
    pointer-events: none;
  }
  .hp-city.has-more:hover .hp-city__more {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
}

.hp-city__more-title {
  display: block;
  font-size: 0.7em;
  font-weight: 750;
  color: var(--hp-brand);
}

.hp-city__facts {
  display: grid;
  gap: 0.28rem;
}

.hp-city__fact {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.18rem 0;
  border-bottom: 1px dashed rgba(45, 46, 125, 0.12);
  font-size: 0.72em;
  line-height: 1.35;
}

.hp-city__fact:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.hp-city__fact > span {
  color: var(--hp-muted);
  flex: 1 1 auto;
  min-width: 0;
}

.hp-city__fact > strong {
  color: var(--hp-ink);
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  text-align: left;
  white-space: nowrap;
}

.hp-city__fact--story {
  display: block;
  margin-top: 0.1rem;
  padding: 0.35rem 0.45rem;
  border: 0;
  border-radius: 8px;
  background: rgba(45, 46, 125, 0.05);
  color: var(--hp-ink);
  font-size: 0.7em;
  line-height: 1.5;
  font-weight: 550;
}

.hp-city__name {
  margin: 0 0 0.15rem;
  font-size: 0.92em;
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-city__toman {
  margin: 0;
  font-size: 0.95em;
  color: var(--hp-brand);
  line-height: 1.3;
}

.hp-city__toman strong {
  font-size: 1.2em;
  font-variant-numeric: tabular-nums;
}

.hp-city__toman span,
.hp-city__usd span,
.hp-city__gold span {
  color: var(--hp-muted);
  font-weight: 500;
  font-size: 0.82em;
}

.hp-city__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.65rem;
  margin-top: 0.15rem;
  font-size: 0.8em;
  font-variant-numeric: tabular-nums;
}

.hp-city__usd {
  margin: 0;
  color: var(--hp-ink);
}

.hp-city__gold {
  margin: 0;
  color: #8a6410;
  font-weight: 650;
}

.hp-cities__empty {
  margin: 0;
  grid-column: 1 / -1;
  color: var(--hp-muted);
  font-size: 0.9em;
}

/* —— Tehran 22 districts table —— */
.hp-teh {
  padding: 1.1rem 1.15rem 1.2rem;
  background: var(--hp-card);
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
}

.hp-teh__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.85rem;
}

.hp-teh__title {
  margin: 0 0 0.25rem;
  font-size: 1.08em;
  font-weight: 700;
  color: var(--hp-ink);
}

.hp-teh__sub {
  margin: 0;
  font-size: 0.84em;
  color: var(--hp-muted);
  max-width: 40rem;
}

.hp-teh__sort select {
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  padding: 0.4rem 0.55rem;
  background: #fff;
  color: var(--hp-ink);
  font: inherit;
}

.hp-teh__scroll {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  max-height: 28.5rem; /* ~8–9 body rows + sticky header */
  overflow-x: auto;
  overflow-y: auto;
  border: 1px solid var(--hp-line);
  border-radius: 12px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(45, 46, 125, 0.28) transparent;
}

.hp-teh__scroll::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.hp-teh__scroll::-webkit-scrollbar-track {
  background: transparent;
}

.hp-teh__scroll::-webkit-scrollbar-thumb {
  background: rgba(45, 46, 125, 0.25);
  border-radius: 8px;
}

.hp-teh__scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(45, 46, 125, 0.4);
}

.hp-teh__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9em;
  min-width: 640px;
}

.hp-teh__table th,
.hp-teh__table td {
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--hp-line);
  text-align: right;
  vertical-align: middle;
}

.hp-teh__table thead th {
  background: var(--hp-bg);
  color: var(--hp-muted);
  font-weight: 600;
  font-size: 0.82em;
  position: sticky;
  top: 0;
  z-index: 2;
  box-shadow: 0 1px 0 var(--hp-line);
}

/* Beat theme `th` backgrounds so zebra rows stay readable */
.hp-teh__table tbody tr:nth-child(odd) > th,
.hp-teh__table tbody tr:nth-child(odd) > td {
  background: #fff !important;
  color: var(--hp-ink);
}

.hp-teh__table tbody tr:nth-child(even) > th,
.hp-teh__table tbody tr:nth-child(even) > td {
  background: rgba(45, 46, 125, 0.045) !important;
  color: var(--hp-ink);
}

.hp-teh__table tbody tr:hover > th,
.hp-teh__table tbody tr:hover > td {
  background: rgba(45, 46, 125, 0.08) !important;
}

.hp-teh__table tbody th {
  font-weight: 700;
  color: var(--hp-brand) !important;
  white-space: nowrap;
}

.hp-teh__hint {
  color: var(--hp-muted);
  font-size: 0.9em;
}

.hp-teh__unit {
  color: var(--hp-muted);
  font-size: 0.85em;
  font-weight: 500;
}

.hp-teh__note {
  margin: 0.7rem 0 0;
  font-size: 0.78em;
  color: var(--hp-muted);
}

@media (max-width: 720px) {
  .hp-teh__scroll {
    max-height: 20rem; /* ~6–7 rows on mobile */
  }
}

@media (max-width: 1100px) {
  .hp-rates {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hp-insights {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    grid-auto-rows: auto;
  }
  .hp-insight.is-featured {
    grid-column: 1 / -1;
    grid-row: auto;
    align-self: start;
    height: auto;
    min-height: 0;
  }
  .hp-insight.is-featured .hp-insight__face {
    height: auto;
  }
  .hp-insight.is-featured .hp-insight__note {
    margin-top: 0.55rem;
  }
  .hp-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hp-cities__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .hp-stats,
  .hp-rates,
  .hp-insights {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hp-insights {
    gap: 0.4rem;
    align-items: start;
    grid-auto-rows: auto;
    overflow: visible;
  }
  .hp-insight:not(.is-featured) {
    height: auto;
    min-height: 0;
  }
  .hp-insight.is-featured {
    grid-column: 1 / -1;
  }
  /*
   * Mobile open: keep grid seat (no row jump).
   * Details float as a wide sheet under the card and overlay neighbors.
   */
  .hp-insights:has(.hp-insight:not(.is-featured).is-open) > .hp-insight:not(.is-open):not(.is-featured),
  .hp-insights:has(.hp-insight:not(.is-featured):focus-visible) > .hp-insight:not(:focus-visible):not(.is-open):not(.is-featured) {
    opacity: 0.42;
    filter: saturate(0.75);
    transition: opacity 0.3s ease, filter 0.3s ease;
  }
  .hp-insight:not(.is-featured).has-more {
    overflow: visible;
  }
  .hp-insight:not(.is-featured).has-more.is-open,
  .hp-insight:not(.is-featured).has-more:focus-visible {
    grid-column: auto;
    width: auto;
    max-width: none;
    margin-inline-start: 0;
    z-index: 60;
    transform: translateY(-3px);
    border-radius: 12px;
    border-end-start-radius: 0;
    border-end-end-radius: 0;
    box-shadow: 0 8px 22px rgba(45, 46, 125, 0.12);
  }
  .hp-insight:not(.is-featured) .hp-insight__more {
    position: absolute;
    top: calc(100% - 1px);
    inset-inline-start: 0;
    inset-inline-end: auto;
    width: calc(200% + 0.4rem);
    max-width: calc(100vw - 1.4rem);
    z-index: 61;
    background: #fff;
    border: 1px solid transparent;
    border-radius: 0 0 14px 14px;
    box-shadow: none;
  }
  /* Left column (RTL): grow toward inline-start so sheet covers the pair */
  .hp-insights > .hp-insight:not(.is-featured):nth-child(odd) .hp-insight__more {
    inset-inline-start: calc(-100% - 0.4rem);
  }
  .hp-insight:not(.is-featured).has-more.is-open .hp-insight__more,
  .hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__more {
    max-height: 24rem;
    opacity: 1;
    pointer-events: auto;
    padding: 0.55rem 0.95rem 0.95rem;
    border-color: rgba(45, 46, 125, 0.3);
    border-top: 1px dashed rgba(45, 46, 125, 0.14);
    background:
      linear-gradient(180deg, #f7f8ff 0%, #fff 28%);
    box-shadow:
      0 22px 44px rgba(45, 46, 125, 0.18),
      0 1px 0 rgba(255, 255, 255, 0.9) inset;
  }
  .hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact,
  .hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact {
    gap: 0.55rem;
    padding: 0.32rem 0;
  }
  .hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact--story,
  .hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact--story {
    padding: 0.5rem 0.65rem;
    margin-inline: 0;
  }
  .hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact > strong,
  .hp-insight:not(.is-featured).has-more:focus-visible .hp-insight__fact > strong {
    white-space: normal;
    overflow-wrap: anywhere;
    max-width: 55%;
  }
  .hp-insight,
  .hp-insight.is-featured {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 0;
    padding: 0;
    border-radius: 12px;
    --hp-insight-pad: 0.65rem 0.85rem 0.7rem;
    --hp-insight-pad-x: 0.95rem;
  }
  .hp-insight.is-featured {
    --hp-insight-pad: 0.7rem 0.75rem 0.75rem;
  }
  .hp-insight__face {
    gap: 0.12rem;
  }
  .hp-insight.is-featured .hp-insight__face {
    padding-inline-start: 0.95rem;
    gap: 0.18rem;
  }
  .hp-insight.is-featured .hp-insight__more {
    padding-inline-start: 0.95rem;
  }
  .hp-insight.has-more:focus-visible,
  .hp-insight.is-open,
  .hp-insight.is-featured.has-more:focus-visible,
  .hp-insight.is-featured.is-open {
    transform: none;
  }
  .hp-insight__more-title {
    font-size: 0.68em;
  }
  .hp-insight__fact {
    font-size: 0.68em;
    gap: 0.4rem;
    padding: 0.2rem 0;
  }
  .hp-insight__fact--story {
    font-size: 0.66em;
    padding: 0.35rem 0.4rem;
  }
  .hp-insight:not(.is-featured).is-open {
    z-index: 40;
  }
  .hp-city.is-open {
    z-index: 4;
  }
  .hp-insight.is-featured.is-open .hp-insight__more,
  .hp-city.is-open .hp-city__more {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
  /* Prefer reduced motion: snap open without tall expand */
  @media (prefers-reduced-motion: reduce) {
    .hp-insight:not(.is-featured) .hp-insight__more,
    .hp-insight:not(.is-featured).has-more:hover .hp-insight__fact,
    .hp-insight:not(.is-featured).has-more.is-open .hp-insight__fact {
      animation: none !important;
      transition: none !important;
    }
  }
  .hp-insight.is-featured::before {
    width: 5rem;
    height: 5rem;
    opacity: 0.7;
  }
  .hp-insight.is-featured::after {
    top: 0.6rem;
    bottom: 0.6rem;
  }
  .hp-insight__badge {
    font-size: 0.6em;
    padding: 0.14rem 0.4rem;
    margin-bottom: 0;
  }
  .hp-insight__eye {
    font-size: 0.68em;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
    min-height: 0;
  }
  .hp-insight.is-featured .hp-insight__eye {
    font-size: 0.72em;
    -webkit-line-clamp: 1;
    line-clamp: 1;
  }
  .hp-insight__value {
    font-size: 1.08rem;
    line-height: 1.15;
  }
  .hp-insight.is-featured .hp-insight__value {
    font-size: 1.45rem;
    margin-top: 0;
  }
  .hp-insight__unit {
    font-size: 0.7em;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
  }
  .hp-insight.is-featured .hp-insight__unit {
    font-size: 0.74em;
  }
  .hp-insight__note {
    margin-top: 0.2rem;
    padding-top: 0;
    font-size: 0.66em;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
  }
  .hp-insight.is-featured .hp-insight__note {
    margin-top: 0.35rem;
    padding-top: 0.4rem;
    font-size: 0.68em;
  }
  .hp-cities__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
  }
  .hp-cities__head {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    margin-bottom: 0.5rem;
  }
  .hp-city {
    --hp-city-pad: 0.5rem 0.55rem 0.55rem;
    padding: 0;
    border-radius: 10px;
  }
  .hp-city__face {
    gap: 0.12rem;
  }
  .hp-city:focus-visible,
  .hp-city.is-open {
    transform: none;
  }
  .hp-city__hint {
    font-size: 0.58em;
  }
  .hp-city__fact {
    font-size: 0.66em;
  }
  .hp-city__fact--story {
    font-size: 0.64em;
  }
  .hp-city__name {
    margin: 0;
    font-size: 0.84em;
  }
  .hp-city__toman {
    font-size: 0.82em;
  }
  .hp-city__toman strong {
    font-size: 1.05em;
  }
  .hp-city__meta {
    margin-top: 0.05rem;
    gap: 0.15rem 0.45rem;
    font-size: 0.72em;
  }
}

@media (max-width: 480px) {
  .hp-top {
    padding: 0.95rem 0.9rem 1rem;
  }
  .hp-stats {
    grid-template-columns: 1fr;
  }
  .hp-rates {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hp-insights,
  .hp-cities__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hp-insights {
    align-items: start;
    grid-auto-rows: auto;
  }
  .hp-cities__grid {
    grid-auto-rows: 1fr;
  }
  .hp-city {
    height: 100%;
    align-content: start;
  }
  /* Hide unit words on tiny screens — numbers already convey the meaning */
  .hp-city__toman > span {
    display: none;
  }
  .hp-city__usd span,
  .hp-city__gold span {
    font-size: 0.9em;
  }
}

/* —— Analytics charts + tools (from former dashboard shortcode) —— */
.hp-analytics {
  margin-top: 1.25rem;
  display: grid;
  gap: 1rem;
}

.hp-analytics__intro {
  margin: 0;
}

.hp-analytics__title {
  margin: 0 0 0.25rem;
  font-size: 1.12em;
  font-weight: 750;
  color: var(--hp-ink);
}

.hp-analytics__lead {
  margin: 0;
  color: var(--hp-muted);
  font-size: 0.88em;
  line-height: 1.5;
}

.hp-analytics__charts,
.hp-analytics__tools,
.hp-analytics__calcs {
  display: grid;
  gap: 0.85rem;
  align-items: start;
}

.hp-analytics__charts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hp-analytics__charts > .hp-returns-card {
  grid-column: 1 / -1;
}

.hp-returns-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -0.15rem;
  padding: 0 0.15rem;
}

.hp-returns-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9em;
  min-width: 640px;
}

.hp-returns-table th,
.hp-returns-table td {
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--hp-line);
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.hp-returns-table thead th {
  background: var(--hp-bg);
  color: var(--hp-muted);
  font-weight: 600;
  font-size: 0.82em;
}

.hp-returns-table thead th:first-child,
.hp-returns-table tbody th {
  text-align: right;
}

.hp-returns-table tbody th {
  font-weight: 700;
  color: var(--hp-brand);
}

.hp-returns-table tbody tr:nth-child(odd) > th,
.hp-returns-table tbody tr:nth-child(odd) > td {
  background: #fff;
}

.hp-returns-table tbody tr:nth-child(even) > th,
.hp-returns-table tbody tr:nth-child(even) > td {
  background: rgba(45, 46, 125, 0.045);
}

.hp-returns-table tbody tr:hover > th,
.hp-returns-table tbody tr:hover > td {
  background: rgba(45, 46, 125, 0.08);
}

.hp-returns-table td {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  direction: ltr;
  unicode-bidi: isolate;
}

.hp-returns-table td.is-up {
  color: #0f7a4c;
}

.hp-returns-table td.is-down {
  color: #b42318;
}

.hp-returns-table td.is-flat {
  color: var(--hp-muted);
}

.hp-returns-swatch {
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  margin-left: 0.4rem;
  vertical-align: middle;
}

.hp-returns-swatch--housing {
  background: #2d2e7d;
}

.hp-returns-swatch--usd {
  background: #0f7a4c;
}

.hp-returns-swatch--gold {
  background: #b8862d;
}

.hp-trend-toolbar {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  padding: 0.55rem 0.7rem;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--hp-line);
  box-shadow: var(--hp-shadow);
}

.hp-app .hp-trend-tabs {
  display: inline-flex;
  align-items: stretch;
  gap: 0;
  padding: 3px;
  border-radius: 10px;
  background: var(--hp-brand-soft);
  border: 1px solid rgba(45, 46, 125, 0.12);
}

.hp-app .hp-trend-tabs__btn {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  padding: 0.4rem 0.9rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--hp-muted);
  font: inherit;
  font-size: 0.86em;
  font-weight: 700;
  line-height: 1.35;
  cursor: pointer;
  box-shadow: none;
}

.hp-app .hp-trend-tabs__btn:hover {
  color: var(--hp-brand);
}

.hp-app .hp-trend-tabs__btn.is-active {
  background: #fff;
  color: var(--hp-brand);
  box-shadow: 0 1px 2px rgba(45, 46, 125, 0.12), 0 0 0 1px rgba(45, 46, 125, 0.06);
}

.hp-app .hp-trend-series {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.hp-app .hp-trend-series__btn {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(45, 46, 125, 0.16);
  background: #fff;
  color: var(--hp-ink);
  font: inherit;
  font-size: 0.82em;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  box-shadow: none;
  transition: background 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
}

.hp-app .hp-trend-series__btn.is-off {
  opacity: 0.45;
  background: rgba(243, 244, 248, 0.9);
  color: var(--hp-muted);
}

.hp-app .hp-trend-series__btn:hover {
  border-color: rgba(45, 46, 125, 0.32);
}

.hp-trend-series__swatch {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  flex: 0 0 auto;
}

.hp-trend-series__swatch--housing {
  background: #2d2e7d;
}

.hp-trend-series__swatch--usd {
  background: #0f7a4c;
}

.hp-trend-series__swatch--gold {
  background: #b8862d;
}

.hp-analytics__tools {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hp-analytics__calcs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
}

.hp-analytics__calcs > .hp-analytics__card {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.hp-analytics__calcs > .hp-analytics__card > .hp-analytics__card-head {
  flex: 0 0 auto;
}

.hp-analytics__calcs > .hp-analytics__card > .hp-tool-form {
  flex: 1 1 auto;
}

.hp-analytics__calcs > .hp-analytics__card > .hp-tool-out,
.hp-analytics__calcs > .hp-analytics__card > .hp-tool-out--panel {
  margin-top: auto;
}

/* Chart panes: capped height + vertical scroll (JS syncs to budget card) */
.hp-analytics__tools > .hp-analytics__card:not(.hp-analytics__card--form) {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.hp-analytics__tools .hp-chart-scroll {
  flex: 0 0 auto;
  min-height: 0;
  max-height: 22rem;
  overflow-x: hidden;
  overflow-y: auto;
}

.hp-budget-city[hidden],
.hp-combobox__list[hidden] {
  display: none !important;
}

.hp-analytics__card {
  margin: 0;
  padding: 0.95rem 1rem 1.05rem;
  background: var(--hp-card);
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
  min-width: 0;
  position: relative;
  overflow: visible;
  isolation: auto;
  z-index: 1;
}

/* Keep help popovers above neighboring cards/charts. */
.hp-analytics__card:hover,
.hp-analytics__card:focus-within,
.hp-analytics__card:has(.hp-chart-help.is-open),
.hp-analytics__card:has(.hp-chart-help:hover) {
  z-index: 8;
}

.hp-analytics__charts > .hp-analytics__card:hover,
.hp-analytics__charts > .hp-analytics__card:focus-within {
  z-index: 10;
}

.hp-analytics__card--pulse {
  background:
    radial-gradient(90% 70% at 100% 0%, rgba(45, 46, 125, 0.1), transparent 55%),
    linear-gradient(165deg, #fff 0%, #f6f7fd 100%);
}

.hp-analytics__card--afford {
  background:
    radial-gradient(80% 60% at 0% 100%, rgba(45, 46, 125, 0.08), transparent 50%),
    #fff;
}

.hp-analytics__card--rent {
  background:
    radial-gradient(80% 60% at 100% 100%, rgba(45, 46, 125, 0.07), transparent 52%),
    #fff;
}

.hp-analytics__card--age {
  background:
    radial-gradient(90% 70% at 0% 0%, rgba(212, 168, 75, 0.14), transparent 55%),
    linear-gradient(165deg, #fffef9 0%, #fff 60%);
  border-color: rgba(184, 134, 45, 0.22);
}

.hp-analytics__card-head h3,
.hp-analytics__card-head h4 {
  margin: 0 0 0.2rem;
  font-size: 1em;
  font-weight: 750;
  color: var(--hp-ink);
}

.hp-analytics__title-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.hp-analytics__title-row h3 {
  margin: 0;
}

.hp-chart-help {
  position: relative;
  display: inline-flex;
  vertical-align: middle;
  flex: 0 0 auto;
  z-index: 2;
}

.hp-chart-help.is-open,
.hp-chart-help:hover,
.hp-chart-help:focus-within {
  z-index: 60;
}

.hp-chart-help__btn {
  width: 1.35rem;
  height: 1.35rem;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(45, 46, 125, 0.28);
  background: #f4f5fb;
  color: #2d2e7d;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  cursor: help;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.hp-chart-help__btn:hover,
.hp-chart-help__btn:focus-visible,
.hp-chart-help.is-open .hp-chart-help__btn {
  background: #2d2e7d;
  border-color: #2d2e7d;
  color: #fff;
  outline: none;
}

.hp-chart-help__panel {
  position: absolute;
  top: calc(100% + 0.45rem);
  right: 0;
  z-index: 80;
  width: min(20rem, calc(100vw - 2.5rem));
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  background: #1f2430;
  color: #f5f6fa;
  font-size: 0.8rem;
  font-weight: 500;
  line-height: 1.65;
  box-shadow: 0 10px 28px rgba(20, 24, 40, 0.28);
  text-align: right;
  pointer-events: none;
}

.hp-chart-help__panel.is-fixed {
  position: fixed !important;
  right: auto !important;
  margin: 0;
  pointer-events: auto;
  max-width: calc(100vw - 24px);
}

.hp-chart-help__panel[hidden] {
  display: none !important;
}

.hp-chart-help__panel::before {
  content: '';
  position: absolute;
  top: -6px;
  right: 0.55rem;
  width: 10px;
  height: 10px;
  background: #1f2430;
  transform: rotate(45deg);
}

.hp-chart-help__panel.is-above::before {
  top: auto;
  bottom: -6px;
}

.hp-chart-help .screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (hover: hover) and (pointer: fine) {
  .hp-chart-help:hover .hp-chart-help__panel,
  .hp-chart-help:focus-within .hp-chart-help__panel {
    display: block !important;
  }

  .hp-chart-help:hover .hp-chart-help__panel[hidden],
  .hp-chart-help:focus-within .hp-chart-help__panel[hidden] {
    display: block !important;
  }
}

@media (max-width: 640px) {
  .hp-chart-help__panel {
    right: auto;
    left: 0;
    width: min(18.5rem, calc(100vw - 2rem));
  }

  .hp-chart-help__panel::before {
    right: auto;
    left: 0.55rem;
  }
}

.hp-seo-block {
  margin-top: 1.25rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--hp-line);
  box-shadow: var(--hp-shadow);
}

.hp-seo-block__title {
  margin: 0 0 0.55rem;
  font-size: 1.08em;
  font-weight: 750;
  color: var(--hp-ink);
}

.hp-seo-block__body {
  display: grid;
  gap: 0.65rem;
  color: var(--hp-muted);
  font-size: 0.9em;
  line-height: 1.7;
}

.hp-seo-block__body > p {
  margin: 0;
}

.hp-faq {
  margin-top: 1.35rem;
  padding: 1.15rem;
  border-radius: 18px;
  background:
    radial-gradient(80% 70% at 100% 0%, rgba(45, 46, 125, 0.08), transparent 55%),
    linear-gradient(180deg, #eef0f7 0%, #f6f7fb 100%);
  border: 1px solid rgba(45, 46, 125, 0.08);
}

.hp-faq__panel {
  max-width: 52rem;
  margin: 0 auto;
}

.hp-faq__head {
  position: relative;
  text-align: center;
  margin-bottom: 1rem;
  padding-top: 0.15rem;
}

.hp-faq__guide {
  position: absolute;
  top: 0;
  right: 0;
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(45, 46, 125, 0.1);
  color: var(--hp-brand);
  font-size: 0.78em;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(45, 46, 125, 0.12);
  transition: background 0.15s ease, color 0.15s ease;
}

.hp-faq__guide:hover,
.hp-faq__guide:focus-visible {
  background: var(--hp-brand);
  color: #fff;
  outline: none;
}

.hp-faq__title {
  margin: 0 0 0.35rem;
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-weight: 800;
  color: var(--hp-brand);
  line-height: 1.35;
}

.hp-faq__lead {
  margin: 0 auto;
  max-width: 36rem;
  color: var(--hp-muted);
  font-size: 0.88em;
  line-height: 1.6;
}

.hp-faq__list {
  display: grid;
  gap: 0.65rem;
}

.hp-faq__item {
  margin: 0;
  border-radius: 14px;
  background: #fff;
  border: 1px solid rgba(45, 46, 125, 0.08);
  box-shadow: 0 8px 22px rgba(45, 46, 125, 0.06);
  overflow: hidden;
}

.hp-faq__item summary {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  cursor: pointer;
  list-style: none;
}

.hp-faq__item summary::-webkit-details-marker {
  display: none;
}

.hp-faq__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.1rem;
  height: 2.1rem;
  padding: 0 0.35rem;
  border-radius: 10px;
  background: var(--hp-brand);
  color: #fff;
  font-size: 0.78em;
  font-weight: 800;
  letter-spacing: 0.02em;
  direction: ltr;
  unicode-bidi: isolate;
}

.hp-faq__q {
  font-weight: 750;
  color: var(--hp-ink);
  font-size: 0.95em;
  line-height: 1.45;
  text-align: right;
}

.hp-faq__chev {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  border: 1px solid rgba(45, 46, 125, 0.16);
  background: var(--hp-brand-soft);
  position: relative;
  flex: 0 0 auto;
  transition: transform 0.2s ease, background 0.15s ease, border-color 0.15s ease;
}

.hp-faq__chev::before {
  content: '';
  position: absolute;
  top: 46%;
  left: 50%;
  width: 0.42rem;
  height: 0.42rem;
  border-right: 2px solid var(--hp-brand);
  border-bottom: 2px solid var(--hp-brand);
  transform: translate(-50%, -60%) rotate(45deg);
}

.hp-faq__item[open] .hp-faq__chev {
  background: var(--hp-brand);
  border-color: var(--hp-brand);
  transform: rotate(180deg);
}

.hp-faq__item[open] .hp-faq__chev::before {
  border-color: #fff;
}

.hp-faq__a {
  padding: 0 1rem 1rem 1rem;
  padding-right: calc(1rem + 2.1rem + 0.75rem);
}

.hp-faq__a p {
  margin: 0;
  color: var(--hp-muted);
  font-size: 0.9em;
  line-height: 1.75;
}

.hp-faq__src {
  display: inline;
  margin-right: 0.15em;
  font-size: 0.82em;
  font-weight: 500;
  color: #8a8ba3;
  text-decoration: none;
  border-bottom: 1px dotted rgba(92, 94, 122, 0.45);
}

.hp-faq__src:hover,
.hp-faq__src:focus-visible {
  color: var(--hp-muted);
  border-bottom-style: solid;
  outline: none;
}

@media (max-width: 720px) {
  .hp-faq {
    padding: 0.9rem;
  }

  .hp-faq__guide {
    position: static;
    margin: 0 auto 0.75rem;
  }

  .hp-faq__item summary {
    gap: 0.55rem;
    padding: 0.8rem 0.8rem;
  }

  .hp-faq__a {
    padding: 0 0.8rem 0.85rem;
  }
}

.hp-analytics__card-head p {
  margin: 0 0 0.75rem;
  font-size: 0.8em;
  color: var(--hp-muted);
  line-height: 1.45;
}

/* Title on the right, scope tabs on the left — same header row. */
.hp-analytics__card-head--row {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.75rem;
}

.hp-analytics__card-head--row .hp-analytics__card-copy {
  flex: 1 1 auto;
  min-width: 0;
}

.hp-analytics__card-head--row .hp-analytics__card-copy h3,
.hp-analytics__card-head--row .hp-analytics__card-copy h4 {
  margin: 0 0 0.2rem;
}

.hp-analytics__card-head--row .hp-analytics__card-copy p {
  margin: 0;
}

.hp-analytics__card-head--row .hp-scope-tabs {
  flex: 0 0 auto;
  margin: 0;
  align-self: flex-start;
}

.hp-analytics__card-head--row .hp-scope-tabs .hp-list-tabs__btn {
  font-size: 0.78em;
  padding: 0.36rem 0.7rem;
  white-space: nowrap;
}

@media (max-width: 720px) {
  .hp-analytics__card-head--row {
    flex-wrap: wrap;
  }

  .hp-analytics__card-head--row .hp-scope-tabs {
    width: 100%;
    order: 2;
  }

  .hp-analytics__card-head--row .hp-scope-tabs .hp-list-tabs__btn {
    flex: 1 1 0;
    white-space: normal;
    text-align: center;
  }
}

.hp-analytics__eyebrow {
  display: inline-flex;
  margin: 0 0 0.28rem;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.68em;
  font-weight: 750;
  letter-spacing: 0.02em;
  color: var(--hp-brand);
  background: rgba(45, 46, 125, 0.08);
  border: 1px solid rgba(45, 46, 125, 0.12);
}

.hp-analytics__card--age .hp-analytics__eyebrow {
  color: #6e4f0c;
  background: rgba(184, 134, 45, 0.14);
  border-color: rgba(184, 134, 45, 0.28);
}

.hp-pulse {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
  align-content: stretch;
}

.hp-analytics__calcs > .hp-analytics__card--pulse > .hp-pulse {
  flex: 1 1 auto;
  min-height: 0;
  grid-auto-rows: 1fr;
}

.hp-analytics__calcs > .hp-analytics__card--pulse .hp-pulse__item {
  align-content: center;
  min-height: 4.2rem;
  height: 100%;
}

.hp-pulse__item {
  display: grid;
  gap: 0.12rem;
  padding: 0.65rem 0.7rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(45, 46, 125, 0.1);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) inset;
}

.hp-pulse__item--gold {
  border-color: rgba(184, 134, 45, 0.28);
  background: linear-gradient(165deg, #fffdf6, #fff8e8);
}

.hp-pulse__item--usd {
  border-color: rgba(45, 46, 125, 0.16);
}

.hp-pulse__k {
  font-size: 0.72em;
  color: var(--hp-muted);
  font-weight: 600;
}

.hp-pulse__v {
  font-size: 1.2em;
  font-weight: 800;
  color: var(--hp-brand);
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
}

.hp-pulse__item--gold .hp-pulse__v {
  color: #8a6410;
}

.hp-pulse__u {
  font-size: 0.72em;
  color: var(--hp-muted);
}

.hp-pulse__note {
  margin: 0.65rem 0 0;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(45, 46, 125, 0.05);
  border: 1px solid rgba(45, 46, 125, 0.1);
  font-size: 0.76em;
  line-height: 1.55;
  color: var(--hp-muted);
}

.hp-pulse__note strong {
  color: var(--hp-ink);
  font-weight: 700;
}

.hp-analytics__calcs > .hp-analytics__card--pulse > .hp-pulse__note {
  margin-top: auto;
}

.hp-tool-grid2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.hp-tool-out--panel {
  margin-top: 0.75rem;
  padding: 0.7rem 0.75rem;
  border-radius: 12px;
  background: rgba(45, 46, 125, 0.05);
  border: 1px solid rgba(45, 46, 125, 0.1);
  min-height: 2.6rem;
}

.hp-tool-out--panel:empty {
  display: none;
}

.hp-chart-wrap {
  position: relative;
  width: 100%;
  overflow: visible;
}

.hp-chart-scroll {
  max-height: 18.5rem; /* ~10 استان در دید؛ بقیه با اسکرول عمودی */
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-inline-end: 0.2rem;
  border-radius: 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(45, 46, 125, 0.35) transparent;
}

.hp-chart-scroll::-webkit-scrollbar {
  width: 6px;
}

.hp-chart-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.hp-chart-scroll::-webkit-scrollbar-thumb {
  background: rgba(45, 46, 125, 0.28);
  border-radius: 999px;
}

.hp-chart-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(45, 46, 125, 0.42);
}

.hp-canvas {
  width: 100%;
  display: block;
  cursor: crosshair;
  max-width: 100%;
}

.hp-chart-wrap > .hp-canvas[data-hp="chart-yearly"] {
  height: 260px;
}

.hp-chart-wrap > .hp-canvas[data-hp="chart-recent"] {
  height: 280px;
}

.hp-chart-tip {
  position: absolute;
  z-index: 8;
  transform: translate(-50%, calc(-100% - 12px));
  pointer-events: none;
  background: rgba(28, 29, 51, 0.96);
  color: #fff;
  border-radius: 12px;
  padding: 0.55rem 0.7rem 0.6rem;
  font-size: 0.78em;
  min-width: 11.5rem;
  max-width: min(18rem, calc(100% - 1rem));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
  text-align: right;
  line-height: 1.35;
  box-sizing: border-box;
}

.hp-chart-tip.is-below {
  transform: translate(-50%, 8px);
}

.hp-chart-tip__title {
  display: block;
  margin: 0 0 0.4rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  font-weight: 800;
  font-size: 1.02em;
  white-space: nowrap;
}

.hp-chart-tip__body {
  display: grid;
  gap: 0.35rem;
}

.hp-chart-tip__row {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 0.45rem;
  row-gap: 0.08rem;
  align-items: center;
  line-height: 1.3;
}

.hp-chart-tip__name {
  grid-column: 1;
  grid-row: 1 / span 2;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 700;
  white-space: nowrap;
  align-self: start;
  padding-top: 0.1rem;
}

.hp-chart-tip__name i {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  flex: 0 0 auto;
  display: inline-block;
}

.hp-chart-tip__val {
  grid-column: 2;
  grid-row: 1;
  font-weight: 700;
  white-space: nowrap;
  text-align: left;
  font-variant-numeric: tabular-nums;
}

.hp-chart-tip__meta {
  grid-column: 2;
  grid-row: 2;
  opacity: 0.78;
  font-size: 0.9em;
  white-space: nowrap;
  text-align: left;
}

.hp-chart-tip__meta b[dir='ltr'] {
  display: inline-block;
  font-weight: 700;
  unicode-bidi: isolate;
  direction: ltr;
  margin-inline-start: 0.2rem;
}

.hp-chart-tip[hidden] {
  display: none !important;
}

.hp-tool-form {
  display: grid;
  gap: 0.55rem;
}

.hp-tool-form label {
  display: grid;
  gap: 0.25rem;
  font-size: 0.82em;
  color: var(--hp-muted);
  font-weight: 600;
}

.hp-tool-form input,
.hp-tool-form select,
.hp-combobox__input {
  border: 1px solid var(--hp-line);
  border-radius: 10px;
  padding: 0.45rem 0.55rem;
  font: inherit;
  color: var(--hp-ink);
  background: #fff;
  width: 100%;
  box-sizing: border-box;
}

.hp-combobox {
  display: grid;
  gap: 0.25rem;
  position: relative;
  z-index: 2;
}

.hp-combobox__label {
  font-size: 0.82em;
  color: var(--hp-muted);
  font-weight: 600;
}

.hp-combobox__list {
  position: absolute;
  top: calc(100% - 0.15rem);
  inset-inline: 0;
  z-index: 8;
  margin: 0;
  padding: 0.3rem;
  list-style: none;
  max-height: 12.5rem;
  overflow-x: hidden;
  overflow-y: auto;
  background: #fff;
  border: 1px solid rgba(45, 46, 125, 0.22);
  border-radius: 12px;
  box-shadow: 0 14px 30px rgba(45, 46, 125, 0.14);
  scrollbar-width: thin;
}

.hp-combobox__list[hidden] {
  display: none !important;
}

.hp-combobox__option {
  margin: 0;
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  font-size: 0.86em;
  color: var(--hp-ink);
  cursor: pointer;
}

.hp-combobox__option:hover,
.hp-combobox__option.is-active {
  background: var(--hp-brand);
  color: #fff;
}

.hp-combobox__option.is-muted {
  color: var(--hp-muted);
  cursor: default;
}

.hp-combobox__option.is-muted:hover {
  background: transparent;
  color: var(--hp-muted);
}

.hp-combobox__picked {
  margin: 0.1rem 0 0;
  font-size: 0.76em;
  color: var(--hp-brand);
  font-weight: 650;
}

.hp-budget-city {
  display: grid;
  gap: 0.3rem;
}

.hp-tool-hint {
  margin: 0;
  font-size: 0.74em;
  line-height: 1.45;
  color: var(--hp-muted);
  font-weight: 500;
}

.hp-tool-btn {
  border: 0;
  border-radius: 10px;
  padding: 0.55rem 0.8rem;
  background: var(--hp-brand);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.hp-tool-btn:hover {
  filter: brightness(1.05);
}

.hp-tool-out {
  margin: 0.65rem 0 0;
  font-size: 0.88em;
  line-height: 1.55;
  color: var(--hp-ink);
}

.hp-age-compare {
  display: grid;
  gap: 0.45rem;
  align-content: start;
}

.hp-analytics__calcs > .hp-analytics__card--age > .hp-age-compare {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.hp-analytics__calcs > .hp-analytics__card--age .hp-age-compare__card {
  flex: 1 1 auto;
  align-content: center;
}

.hp-analytics__calcs > .hp-analytics__card--age .hp-age-compare__vs {
  flex: 0 0 auto;
}

.hp-analytics__calcs > .hp-analytics__card--age .hp-age-compare__delta {
  margin-top: auto;
  flex: 0 0 auto;
}

.hp-age-compare__card {
  display: grid;
  gap: 0.2rem;
  padding: 0.75rem 0.8rem;
  border-radius: 12px;
  border: 1px solid var(--hp-line);
}

.hp-age-compare__card--new {
  background: linear-gradient(165deg, #f4f6ff, #eef1ff);
  border-color: rgba(45, 46, 125, 0.16);
}

.hp-age-compare__card--old {
  background: linear-gradient(165deg, #faf8f3, #f3eee4);
  border-color: rgba(184, 134, 45, 0.24);
}

.hp-age-compare__card span {
  color: var(--hp-muted);
  font-size: 0.78em;
  font-weight: 650;
}

.hp-age-compare__card strong {
  color: var(--hp-brand);
  font-size: 1.05em;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.hp-age-compare__card--old strong {
  color: #8a6410;
}

.hp-age-compare__vs {
  justify-self: center;
  font-size: 0.72em;
  font-weight: 700;
  color: var(--hp-muted);
  letter-spacing: 0.04em;
}

.hp-age-compare__delta {
  margin: 0.2rem 0 0;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  font-size: 0.82em;
  font-weight: 650;
  color: #5c4a22;
  line-height: 1.45;
  background: rgba(184, 134, 45, 0.12);
  border: 1px solid rgba(184, 134, 45, 0.22);
}

.hp-age-compare__delta:empty {
  display: none;
}

.hp-analytics__details {
  border-top: 1px solid var(--hp-line);
  padding: 0.55rem 0 0;
  margin-top: 0.35rem;
}

.hp-analytics__details + .hp-analytics__details {
  margin-top: 0.45rem;
}

.hp-analytics__details summary {
  cursor: pointer;
  font-weight: 650;
  font-size: 0.88em;
  color: var(--hp-ink);
}

.hp-analytics__details p {
  margin: 0.4rem 0 0;
  font-size: 0.84em;
  color: var(--hp-muted);
  line-height: 1.55;
}

@media (max-width: 1100px) {
  .hp-analytics__charts,
  .hp-analytics__tools {
    grid-template-columns: 1fr 1fr;
  }
  .hp-analytics__calcs {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .hp-analytics__charts,
  .hp-analytics__tools,
  .hp-analytics__calcs {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hp-map__poly,
  .hp-seg__btn,
  .hp-kind {
    transition: none;
  }
}
