/* ==========================================================================
   Huntingdonshire Business Directory - CATEGORY PAGE (shared by all categories)
   ========================================================================== */

/* Page head (light banner - sits clear of the navy nav) */
.page-head { background: linear-gradient(180deg, var(--accent), var(--accent-dark)); color: #fff; text-align: center; padding-block: clamp(2.4rem, 6vw, 4.2rem); }
.page-head h1 { color: #fff; font-size: clamp(1.9rem, 4.4vw, 3rem); margin-bottom: .5rem; }
.page-head p { color: rgba(255,255,255,.92); font-size: clamp(1.02rem, 2vw, 1.2rem); max-width: 660px; margin: 0 auto; }
.page-head .eyebrow { color: var(--accent-2); }

/* Layout: main listings + right banner sidebar */
.cat-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 2rem; align-items: start; }

/* Accepted business types */
.cat-types { margin-bottom: 2rem; }
.cat-types h2 { font-size: 1.15rem; color: var(--brand); margin-bottom: .8rem; }
.cat-types__list { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: 0; }
.cat-type { background: #fff; border: 1px solid var(--grey-line); color: var(--ink); font-size: .9rem; padding: .4rem .8rem; border-radius: 999px; }

/* Listings */
.listings-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 1.1rem; gap: 1rem; }
.listings-head h2 { font-size: 1.3rem; color: var(--brand); margin: 0; }
.listings-head .count { color: var(--muted); font-size: .95rem; }
.listings { display: grid; gap: 1.2rem; }

.listing { background: #fff; border: 1px solid var(--grey-line); border-radius: var(--radius); padding: 1.5rem; position: relative; }
.listing__tier { position: absolute; top: 1.1rem; right: 1.1rem; font-family: var(--font-head); font-weight: 700; font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.listing__top { display: flex; gap: 1rem; align-items: flex-start; }
.listing__logo { width: 64px; height: 64px; border-radius: 10px; background: var(--grey); border: 1px solid var(--grey-line); object-fit: cover; flex: 0 0 auto; display: grid; place-items: center; color: var(--muted); font-size: 1.4rem; overflow: hidden; }
.listing__logo img { width: 100%; height: 100%; object-fit: cover; }
.listing__name { font-family: var(--font-head); font-weight: 700; color: var(--brand); font-size: 1.2rem; line-height: 1.2; margin: 0; }
.listing__type { color: var(--muted); font-size: .9rem; }
.listing__stars { color: var(--accent-2); font-size: .95rem; margin-top: .25rem; }
.listing__stars .val { color: var(--muted); font-family: var(--font-head); font-size: .82rem; margin-left: .3rem; }
.listing__desc { color: var(--ink); margin: .9rem 0 0; line-height: 1.6; }
.listing__meta { display: flex; flex-wrap: wrap; gap: .5rem 1.3rem; margin-top: 1rem; font-size: .95rem; }
.listing__meta a, .listing__meta span { display: inline-flex; align-items: center; gap: .45rem; color: var(--ink); }
.listing__meta i { color: var(--accent-dark); }
.listing__photos { display: flex; gap: .6rem; margin-top: 1.1rem; flex-wrap: wrap; }
.listing__photos span { width: 92px; height: 68px; border-radius: 8px; background: var(--grey); border: 1px solid var(--grey-line); display: grid; place-items: center; color: var(--muted); font-size: 1.1rem; }
.listing__extra { display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--grey-line); font-size: .92rem; color: var(--muted); }
.listing__extra i { color: var(--accent-dark); margin-right: .4rem; }

/* Tier variations */
.listing--superstar { border: 2px solid var(--accent); box-shadow: var(--shadow-md); }
.listing--superstar .listing__tier { color: var(--accent-dark); }
.listing__badge { position: absolute; top: -11px; left: 1.3rem; background: var(--accent); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; padding: .28rem .8rem; border-radius: 999px; }
.listing--plus { border-left: 4px solid var(--accent-2); }
.listing--free { padding: 1.1rem 1.3rem; }
.listing--free .listing__top { align-items: center; }
.listing--free .listing__logo { width: 44px; height: 44px; font-size: 1rem; }
.listing--free .listing__name { font-size: 1.05rem; }

/* Empty state (navy panel) */
.listings-empty { text-align: center; background: var(--brand); border: 0; border-radius: var(--radius-lg); padding: clamp(2.8rem, 7vw, 4.8rem) clamp(1.6rem, 6vw, 4rem); color: #E7EAF1; }
.listings-empty__icon { width: 84px; height: 84px; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; display: grid; place-items: center; font-size: 2.1rem; margin: 0 auto 1.8rem; }
.listings-empty h2 { font-size: clamp(1.4rem, 3vw, 1.85rem); color: #fff; margin: 0 0 .9rem; line-height: 1.3; }
.listings-empty p { color: #C7CDD8; max-width: 48ch; margin: 0 auto 2.2rem; font-size: 1.06rem; line-height: 1.7; }
.listings-empty__cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2.5rem; }
.listings-empty__suggest { margin-top: 2rem; font-size: .96rem; color: #A9B4C6; line-height: 1.6; }
.listings-empty__suggest a { color: #fff; font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

/* Right-hand banner sidebar (2 spots per category) */
.cat-sidebar { display: grid; gap: 1.2rem; position: sticky; top: 1rem; }
.banner-slot { border: 2px dashed var(--grey-line); border-radius: var(--radius); background: var(--grey); min-height: 380px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: .5rem; padding: 1.6rem; color: var(--muted); }
.banner-slot i { font-size: 1.8rem; color: var(--accent); }
.banner-slot strong { font-family: var(--font-head); color: var(--brand); font-size: 1rem; }
.banner-slot small { font-size: .85rem; }
.banner-slot a { color: var(--accent-dark); font-weight: 600; }
.banner-slot--filled { padding: 0; border: 1px solid var(--grey-line); overflow: hidden; min-height: 0; }
.banner-slot--filled img { display: block; width: 100%; height: auto; }
.banner-inline { display: none; }   /* shown only on mobile, interleaved between listings */

@media (max-width: 900px) {
    .cat-layout { grid-template-columns: 1fr; }
    .cat-sidebar { display: none; }
    .banner-inline { display: block; margin: 1.4rem 0; }
}
@media (max-width: 560px) {
    .cat-sidebar { grid-template-columns: 1fr; }
    .listing__tier { position: static; display: inline-block; margin: 0 0 .6rem; }
    .listing--free .listing__top { flex-direction: column; align-items: flex-start; }
    .listings-empty__cta { flex-direction: column; }
    .listings-empty__cta .btn { width: 100%; max-width: 320px; margin-inline: auto; }
}
