/* =========================================================
   Build Region – popup (6 regions) + header button
   Loaded after the theme styles (see inc/regions.php)
   ========================================================= */

/* ---- Popup ---- */
.region-popup-new .modal-dialog { max-width: 1320px; width: 94%; }
.region-popup-new .modal-dialog .modal-content { padding: 60px 80px 70px; }
.region-popup-new .modal-header { border-bottom: 1px solid #dcdcdc; margin-bottom: 38px; }

.region-popup-new .cyr-btn {
  height: 100%;
  min-height: 90px;
  padding: 12px 15px;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.35;
  color: #3D3C3C;
}
.region-popup-new .cyr-btn span { display: block; }
.region-popup-new .cyr-btn:hover,
.region-popup-new .cyr-btn:focus { background: #F89948; border-color: #F89948; color: #fff; }

/* currently selected region (when the popup is re-opened from the header) */
.region-popup-new .cyr-btn.active { border-color: #5A3E98; box-shadow: inset 0 0 0 1px #5A3E98; }

/* ---- Header "Build Region:" button ---- */
.sd-build-region { display: flex; align-items: center; min-width: 0; color: #fff; }
.sd-build-region .sd-region-current {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  margin-left: 6px;
  color: #fff;
  text-decoration: none;
}
.sd-build-region .sd-region-current .fa { color: #F89948; font-size: 18px; margin-left: 6px; }
.sd-build-region .sd-region-current:hover { color: #F89948; }

/* ---- Tablet ---- */
@media (max-width: 1199px) {
  .region-popup-new .modal-dialog .modal-content { padding: 50px 30px 50px; }
}

/* ---- Mobile ---- */
@media (max-width: 767px) {
  .region-popup-new .modal-dialog .modal-content { padding: 40px 20px; }
  .region-popup-new .modal-header { margin-bottom: 20px; }
  .region-popup-new .cyr-btn { min-height: 70px; font-size: 13px; }

  /* long region names: keep on one line in the top bar */
  .sd-build-region { font-size: 13px; }
  .sd-build-region > span { white-space: nowrap; }
  .sd-build-region .js-region-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

/* =========================================================
   View by Estate – region tabs
   One even row on desktop (matches client mock-up), works for
   any number of tabs (Sydney 6–7, Murray 7). Long names wrap
   inside their own box instead of overflowing.
   ========================================================= */
.tabs-vbe-grd-row ul.tabs-vbe {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin: 0;
  padding: 10px 20px !important;
}
.tabs-vbe-grd-row ul.tabs-vbe li { margin: 0 !important; width: auto !important; }
.tabs-vbe-grd-row ul.tabs-vbe li a {
  width: 100% !important;
  height: 100%;
  min-width: 0 !important;
  min-height: 59px;
  padding: 8px 12px;
  font-size: 15px;
  line-height: 1.3;
  text-align: center;
}

@media (max-width: 991px) {
  .tabs-vbe-grd-row ul.tabs-vbe { grid-template-columns: repeat(2, 1fr); gap: 8px; padding: 5px 10px !important; }
  .tabs-vbe-grd-row ul.tabs-vbe li a { min-height: 44px; font-size: 12px; padding: 5px 8px; }
}
