/* Service listing page (hm-listing). Builds on the tokens and components in hal-al-mushkila-home.css. */

.hm-btn-block { width: 100%; }

/* ── Layout ────────────────────────────────────────────────────── */
.hm-listing-body { padding: 40px 0 72px; background: #fff; }
.hm-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 32px; align-items: start; }
.hm-sidebar, .hm-results { min-width: 0; }
.hm-sidebar { position: sticky; top: 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.hm-side-card { min-width: 0; }
.hm-side-card { background: #fff; border: 1px solid var(--hm-line); border-radius: 20px; padding: 20px; box-shadow: var(--hm-shadow); }
.hm-side-title { display: block; margin: 0 0 12px; font-size: 13px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--hm-ink); }
.hm-input { position: relative; margin-bottom: 12px; }
.hm-input i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--hm-muted); font-size: 18px; pointer-events: none; }
.hm-input input {
    width: 100%; height: 46px; padding: 0 14px 0 42px; border: 1px solid var(--hm-line); border-radius: 12px; background: var(--hm-soft);
    font-size: 14px; color: var(--hm-ink); transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.hm-input input:focus { outline: 0; border-color: var(--hm-blue); background: #fff; box-shadow: 0 0 0 3px rgba(8, 117, 225, .14); }

.hm-catlist, .hm-sublist { display: grid; gap: 2px; }
.hm-catlist a {
    display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 12px;
    font-size: 14px; font-weight: 600; color: var(--hm-text); transition: background-color .15s ease, color .15s ease;
}
.hm-catlist a:hover { background: var(--hm-soft); color: var(--hm-ink); }
.hm-catlist a.is-active { background: #e8f2ff; color: var(--hm-blue-dark); }
.hm-catlist small { min-width: 24px; padding: 2px 8px; border-radius: 999px; background: var(--hm-soft); text-align: center; font-size: 12px; font-weight: 700; color: var(--hm-muted); }
.hm-catlist a.is-active small { background: #fff; color: var(--hm-blue-dark); }
.hm-sublist { margin: 4px 0 6px 14px; padding-left: 12px; border-left: 2px solid var(--hm-line); }
.hm-sublist a { padding: 7px 10px; font-size: 13px; font-weight: 500; }

.hm-side-cta {
    display: flex; align-items: center; gap: 14px; padding: 18px 20px; border-radius: 20px; color: #fff;
    background: linear-gradient(120deg, var(--hm-navy) 0%, #1d4fd8 100%); box-shadow: var(--hm-shadow);
    transition: transform .2s ease;
}
.hm-side-cta:hover { color: #fff; transform: translateY(-2px); }
.hm-side-cta > i { width: 44px; height: 44px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: rgba(255, 255, 255, .16); font-size: 22px; }
.hm-side-cta strong { display: block; font-size: 14.5px; font-weight: 800; line-height: 1.3; }
.hm-side-cta small { display: block; margin-top: 3px; font-size: 12.5px; font-weight: 600; color: rgba(255, 255, 255, .85); }

/* ── Toolbar ───────────────────────────────────────────────────── */
.hm-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.hm-count { font-size: 14.5px; color: var(--hm-muted); }
.hm-count strong { font-size: 18px; font-weight: 800; color: var(--hm-ink); }
.hm-sort { display: flex; align-items: center; gap: 10px; margin: 0; }
.hm-sort label { margin: 0; font-size: 13px; font-weight: 600; color: var(--hm-muted); }
.hm-sort select {
    height: 42px; padding: 0 36px 0 14px; border: 1px solid var(--hm-line); border-radius: 12px; background-color: #fff; cursor: pointer;
    font-size: 14px; font-weight: 600; color: var(--hm-ink);
}
.hm-sort select:focus { outline: 0; border-color: var(--hm-blue); box-shadow: 0 0 0 3px rgba(8, 117, 225, .14); }
.hm-active { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 20px; }
.hm-tag { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: #e8f2ff; color: var(--hm-blue-dark); font-size: 13px; font-weight: 700; }
.hm-tag:hover { background: #d6e8fd; color: var(--hm-blue-dark); }
.hm-clear { margin-left: 4px; font-size: 13px; font-weight: 700; color: #dc2626; }
.hm-clear:hover { color: #b91c1c; text-decoration: underline; }

/* ── Grid & cards on a white page ──────────────────────────────── */
.hm-grid-auto { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.hm-listing .hm-gig { border: 1px solid var(--hm-line); box-shadow: var(--hm-shadow); }
.hm-listing .hm-gig:hover { box-shadow: var(--hm-shadow-lg); }

/* ── Pagination (Bootstrap markup) ─────────────────────────────── */
.hm-pager { display: flex; justify-content: center; margin-top: 36px; }
.hm-pager .pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin: 0; }
.hm-pager .page-link {
    min-width: 42px; height: 42px; display: flex; align-items: center; justify-content: center; padding: 0 12px;
    border: 1px solid var(--hm-line); border-radius: 12px !important; background: #fff; color: var(--hm-ink); font-size: 14px; font-weight: 700; box-shadow: none;
}
.hm-pager .page-link:hover { border-color: var(--hm-blue); color: var(--hm-blue); background: var(--hm-soft); }
.hm-pager .page-item.active .page-link { background: var(--hm-blue); border-color: var(--hm-blue); color: #fff; }
.hm-pager .page-item.disabled .page-link { color: #a3b1c6; background: var(--hm-soft); }

/* ── Empty state ───────────────────────────────────────────────── */
.hm-empty { padding: 64px 24px; text-align: center; border: 1px dashed #cfd9e6; border-radius: 24px; background: var(--hm-soft); }
.hm-empty-icon { width: 72px; height: 72px; margin: 0 auto 18px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: #fff; color: var(--hm-blue); font-size: 34px; box-shadow: var(--hm-shadow); }
.hm-empty h2 { font-size: 22px; font-weight: 800; color: var(--hm-ink); }
.hm-empty p { max-width: 480px; margin: 10px auto 0; font-size: 14.5px; line-height: 1.65; color: var(--hm-muted); }
.hm-empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 24px; }

/* ── Trust band at the foot of the listing (no hero to overlap) ─ */
.hm-listing .hm-trust-band { margin-top: 0; padding-bottom: 40px; }
.hm-listing .hm-listing-body { padding-bottom: 40px; }
.hm-listing .hm-cta-wrap { padding-top: 0; }

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .hm-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
    .hm-sidebar { position: static; }
    .hm-catlist { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
    .hm-catlist::-webkit-scrollbar { display: none; }
    .hm-catlist > li { flex-shrink: 0; }
    .hm-catlist > li > a { border: 1px solid var(--hm-line); border-radius: 999px; padding: 8px 14px; white-space: nowrap; }
    .hm-catlist > li > a.is-active { border-color: #b9d5f7; }
    .hm-sublist { display: none; }
    .hm-side-cta { display: none; }
}
@media (max-width: 575.98px) {
    .hm-toolbar { align-items: flex-start; }
    .hm-sort { width: 100%; }
    .hm-sort select { flex: 1; }
    .hm-grid-auto { grid-template-columns: 1fr; }
}
