.highlight-grid article,
.listing-directory .listing-card {
  display: flex;
  flex-direction: column;
}

.highlight-grid article > div {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.listing-read-more {
  align-self: flex-start;
  margin-top: 14px;
  padding: 0;
  border: 0;
  color: #075f58;
  background: transparent;
  font: inherit;
  font-size: .8rem;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
  cursor: pointer;
}

.listing-directory .listing-read-more {
  margin-top: auto;
  padding-top: 16px;
}

.listing-directory .listing-card-extra { display: none; }
.listing-directory .page-card > p:first-of-type { -webkit-line-clamp: 6; }

.listing-details-dialog {
  width: min(680px, calc(100% - 28px));
  max-height: min(82vh, 760px);
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 8px;
  color: #151622;
  background: #fff;
  box-shadow: 0 28px 90px rgba(7, 8, 22, .32);
}

.listing-details-dialog::backdrop { background: rgba(7, 8, 22, .72); }
.listing-details-panel { position: relative; padding: 30px; }
.listing-details-close { position: absolute; top: 14px; right: 14px; width: 38px; height: 38px; border: 0; border-radius: 50%; color: #fff; background: #070816; font: inherit; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.listing-details-category { padding-right: 45px; color: #138d84; font-size: .72rem; font-weight: 950; letter-spacing: .08em; text-transform: uppercase; }
.listing-details-panel h2 { margin: 8px 45px 22px 0; font-size: clamp(1.65rem, 5vw, 2.5rem); line-height: 1.05; letter-spacing: 0; }
.listing-details-body { display: grid; gap: 16px; }
.listing-details-body section { padding-top: 15px; border-top: 1px solid rgba(7, 8, 22, .1); }
.listing-details-body h3 { margin: 0 0 6px; font-size: .82rem; letter-spacing: 0; }
.listing-details-body p { margin: 0; color: #555c6b; white-space: pre-line; }
.listing-details-offer { padding: 16px; border: 0 !important; border-radius: 8px; background: rgba(25, 211, 197, .12); }
.listing-details-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.listing-detail-link { padding: 10px 13px; border: 1px solid rgba(7, 8, 22, .14); border-radius: 6px; color: #070816; background: #fff; font-size: .82rem; font-weight: 900; overflow-wrap: anywhere; text-decoration: none; }
.listing-detail-link:hover { border-color: #19d3c5; background: rgba(25, 211, 197, .08); }

@media (max-width: 620px) {
  .listing-details-panel { padding: 24px 20px; }
  .listing-details-actions { display: grid; }
  .listing-detail-link { text-align: center; }
}

/* Equal-size directory cards: fixed space for label, name and summary */
.listing-directory .listing-card .listing-tag { display: block; max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.listing-directory .listing-card h3 { display: -webkit-box; min-height: 2.5em; line-height: 1.25; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.listing-directory .page-card > p:first-of-type { height: calc(6 * 1.48em); min-height: 0; }
.listing-detail-enquire { border: 0; cursor: pointer; font: inherit; font-size: .82rem; font-weight: 900; color: #fff; background: #138d84; }
.listing-detail-enquire:hover { color: #fff; background: #0f7a72; }

/* Equal-size home page business cards */
.highlight-grid [hidden] { display: none !important; }
.highlight-grid article { display: flex; flex-direction: column; }
.highlight-grid article > div { flex: 1; display: flex; flex-direction: column; min-height: 238px; }
.highlight-grid article small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.highlight-grid article h3 { display: -webkit-box; min-height: 2.2em; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.highlight-grid article p { height: calc(4 * 1.45em); min-height: 0; -webkit-line-clamp: 4; }
.highlight-grid article .listing-read-more { margin-top: auto; padding-top: 10px; }
