/*
Theme Name: Dapperlance Child
Theme URI: https://hivepress.io/themes/listinghive
Template: listinghive
Description: Dapperlance child theme - Better Messages integration
Version: 1.0
License: GNU General Public License v3 or later
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Text Domain: listinghive-child
*/

/* Import parent theme styles */
@import url("../listinghive/style.css");

/* =====================================================
   DESIGN TOKENS — single source of truth for the palette.
   Every themed rule below reads these variables, so changing
   the site's look = changing this block (or, for live preview,
   the palette switcher panel on dapperlance.local sets the same
   variables via JS — assets/js/palette-preview.js).
   Current palette: "Burgundy — Mellow" (committed 2026-06-13).
   Principle: buttons, links, badges, and ink are DARK burgundy (same hue
   family); backgrounds, hero, chips, and card surfaces are LIGHT blush tints
   of the same family. Side markers keep the functional green / coral so the
   worker-vs-client distinction stays unmistakable (decoupled from the brand
   palette on purpose — see palette-preview.js / dapperlance-design.md).
   ===================================================== */
:root {
    /* Actions — dark burgundy for contrast */
    --dp-primary: #7a2435;          /* buttons, active pills, icon accents */
    --dp-primary-dark: #5e1b28;     /* hover state */
    --dp-on-primary: #ffffff;       /* text on primary / dark badges */
    /* Text */
    --dp-ink: #3a1820;              /* headings / strong text — deep wine */
    --dp-link: #7a2435;             /* text links — same family as primary */
    /* Surfaces — light blush, low priority */
    --dp-bg-page: #fbf7f6;          /* body background (warm near-white) */
    --dp-bg-soft: #f4e9ea;          /* header, title strips, footer, chips */
    --dp-divider: #e7d4d7;          /* borders on soft surfaces */
    /* Homepage hero — light rose band (mellow pastel) */
    --dp-hero-from: #f7e9ea;
    --dp-hero-mid: #f1dde0;
    --dp-hero-to: #ecd3d7;
    --dp-hero-ink: #3a1820;
    --dp-hero-ink-muted: rgba(58, 24, 32, 0.74);
    --dp-hero-pill-border: rgba(58, 24, 32, 0.34);
    /* Category chips — light fill, dark label */
    --dp-chip-bg: #f4e9ea;
    --dp-chip-border: #e3cdd1;
    --dp-chip-ink: #7a2435;
    --dp-chip-count-bg: #b05566;    /* dusty-rose pop on chips (same family) */
    --dp-chip-count-ink: #ffffff;
    /* Secondary accent — dusty rose, the contrasting tone within the family */
    --dp-accent-pop: #b05566;
    /* Side markers — FUNCTIONAL green / coral (worker vs client), kept distinct
       from the burgundy brand on purpose. *-bg tints are for placeholders. */
    --dp-forhire-bar: #186556;
    --dp-forhire-bg:  #e5f0eb;
    --dp-forhire-ink: #ffffff;
    --dp-hiring-bar:  #c44a62;
    --dp-hiring-bg:   #fce9ed;
    --dp-hiring-ink:  #ffffff;
    /* Featured rides a NEUTRAL channel (never a colour) so it can't clash with
       the side markers — a dark wine pill + lifted card. */
    --dp-featured-pill: rgba(58, 24, 32, 0.93);
    --dp-featured-border: #e7d4d7;  /* warm neutral, matches the family */
    /* Listing cards */
    --dp-card-border: #ecdde0;     /* light rose-grey, matches the palette */
    --dp-card-radius: 16px;
    --dp-card-shadow: 0 6px 24px rgba(80, 30, 40, 0.10);
    --dp-radius-btn: 12px;
}

/* Add your custom styles below this line */

/* Message Button Styles */
.listing-message-button-container {
    margin: 1rem 0;
}

.listing-message-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.listing-message-button i {
    margin-right: 0.5rem;
}

/* (Removed the custom "Send Message" amber→green patch — the theme's native
   primary_color is now #2d8a6e, so .button--primary is green site-wide and the
   override is redundant.) */

/* "Sign in to view" link shown to logged-out visitors in place of a gated
   phone number (see dp phone-gate filter in functions.php). */
.dp-phone-locked {
    color: var(--dp-link);
    font-weight: 600;
    text-decoration: underline;
}
.dp-phone-locked:hover,
.dp-phone-locked:focus {
    color: var(--dp-primary-dark);
}

/* Better Messages Custom Styles */
.bp-messages-wrap .chat-header {
    border-bottom: 1px solid #eee;
}

.bp-messages-wrap .threads-list .thread {
    border-bottom: 1px solid #f5f5f5;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .listing-message-button {
        font-size: 0.9rem;
    }
}

/* =====================================================
   Reviews display (custom chat-gated reviews)
   Native HivePress review submission is removed server-side
   (see includes/reviews-display.php), so no CSS hiding is needed.
   ===================================================== */
.dp-reviews__summary {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.dp-reviews__average {
    font-weight: 700;
    font-size: 1.1rem;
}

.dp-reviews__count {
    color: #6b7280;
}

.dp-reviews__disclaimer {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.82rem;
    line-height: 1.5;
    color: #6b7280;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 0.7rem 0.9rem;
    margin: 0 0 1.5rem;
}

.dp-reviews__disclaimer i {
    color: #9ca3af;
    margin-top: 0.15rem;
}

.dp-reviews__list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* ── Two-sided rating in the profile header ──
   Hide HivePress's single native vendor rating ON THE VENDOR PAGE ONLY (it
   reflects just the freelancer bucket); we render both sides ourselves below.
   Scoped to .hp-vendor--view-page so vendor cards in listings/archives keep
   their native rating. */
.hp-vendor--view-page .hp-vendor__rating {
    display: none !important;
}

.dp-profile-ratings {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin: 0.25rem 0 0.5rem;
    text-align: center;
}

.dp-profile-rating {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
}

.dp-profile-rating__label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #6b7280;
}

.dp-profile-rating__row {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.dp-profile-rating__value {
    font-weight: 700;
    color: var(--dp-ink);
}

.dp-profile-rating__count {
    color: #9ca3af;
    font-size: 0.85rem;
}

/* ── Two-sided profile reviews (as a freelancer / as a client) ── */
.dp-reviews__bucket + .dp-reviews__bucket {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.dp-reviews__bucket-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--dp-ink);
    margin: 0 0 0.75rem;
}

.dp-review {
    padding: 1.25rem 0;
    border-top: 1px solid #e5e7eb;
}

.dp-review:first-child {
    border-top: none;
}

.dp-review__header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.dp-review__author {
    font-weight: 600;
}

.dp-review__verified {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.8rem;
    color: #15803d;
    background: #f0fdf4;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
}

.dp-review__meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0.35rem 0 0.5rem;
}

.dp-review__date {
    color: #9ca3af;
    font-size: 0.85rem;
}

.dp-review__text {
    line-height: 1.6;
}

.dp-review__price {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: #6b7280;
}

/* ── Review response (one public reply from the reviewed person) ── */
.dp-review__response {
    margin: 0.85rem 0 0 1.25rem;
    padding: 0.75rem 1rem;
    border-left: 3px solid #e2e8f0;
    background: #f8fafc;
    border-radius: 0 8px 8px 0;
}

.dp-review__response-label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 0.3rem;
}

.dp-review__response-label i {
    color: #94a3b8;
}

.dp-review__response-text {
    font-size: 0.9rem;
    line-height: 1.55;
    color: #334155;
}

/* ── Respond form (shown only to the reviewed person) ── */
.dp-review__respond {
    margin-top: 0.75rem;
}

.dp-review__respond > summary {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--dp-link);
    list-style: none;
    width: fit-content;
}
.dp-review__respond > summary::-webkit-details-marker { display: none; }
.dp-review__respond > summary:hover { color: var(--dp-ink); }

.dp-review__respond-form {
    margin-top: 0.6rem;
}

.dp-review__respond-form textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 0.6rem 0.75rem;
    font-family: inherit;
    font-size: 0.9rem;
    resize: vertical;
    outline: none;
    transition: border-color 0.13s;
}
.dp-review__respond-form textarea:focus { border-color: var(--dp-primary); }

.dp-review__respond-form button {
    margin-top: 0.5rem;
    background: var(--dp-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1.1rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.13s;
}
.dp-review__respond-form button:hover { background: var(--dp-primary-dark); }

/* =====================================================
   Homepage Hero — gradient fallback (no background image)
   ===================================================== */
.header-hero--large:not(.header-hero--cover) {
    background-color: var(--dp-hero-from) !important;
    background-image: linear-gradient(135deg, var(--dp-hero-from) 0%, var(--dp-hero-mid) 60%, var(--dp-hero-to) 100%) !important;
}

/* Hero text color comes from the palette (white on dark heroes,
   dark ink on light heroes like the yellow palette) */
.header-hero--large:not(.header-hero--cover) h1,
.header-hero--large:not(.header-hero--cover) h2,
.header-hero--large:not(.header-hero--cover) p {
    color: var(--dp-hero-ink) !important;
}

.header-hero--large:not(.header-hero--cover) h1 {
    font-size: inherit;
    font-weight: inherit;
    margin: inherit;
}

/* =====================================================
   Homepage sections — Browse & Latest
   ===================================================== */

/* Section headings on the homepage body */
.home .page__text > .dp-section-title,
.home .page__text > h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dp-ink);
    margin: 2.5rem 0 1rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid var(--dp-divider);
}

/* Listings archive page title */
.dp-page__title {
    margin: 0 0 1rem;
}
.page-id-70 .page__text > h3:first-of-type {
    margin-top: 0.5rem;
}

/* =====================================================
   Latest posts grid — dp_latest_posts shortcode
   ===================================================== */
.dp-post-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 0.5rem 0 0;
}
.dp-post-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #e8edf3;
    border-radius: 8px;
    overflow: hidden;
    text-decoration: none;
    transition: box-shadow 0.15s;
}
.dp-post-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.09);
}
.dp-post-card__img img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
}
.dp-post-card__body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}
.dp-post-card__date {
    font-size: 0.75rem;
    color: #9ca3af;
}
.dp-post-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--dp-ink);
    margin: 0;
    line-height: 1.3;
}
.dp-post-card__excerpt {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 0;
    line-height: 1.5;
}
.dp-no-posts {
    color: #9ca3af;
    font-size: 0.9rem;
}
@media (max-width: 768px) {
    .dp-post-grid {
        grid-template-columns: 1fr;
    }
}

/* =====================================================
   Hero search form + Find Talent / Find Work toggle
   ===================================================== */
.header-hero--large:not(.header-hero--cover) .hp-form {
    margin-top: 0;
}

.dp-search-wrap {
    width: 100%;
    margin-top: 1.5rem;
}

.dp-search-toggle {
    display: flex;
    justify-content: center;
    margin-bottom: 0.65rem;
}

.dp-toggle-btn {
    padding: 0.45rem 1.75rem;
    border: 2px solid var(--dp-hero-pill-border);
    background: transparent;
    color: var(--dp-hero-ink-muted);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    line-height: 1;
    letter-spacing: 0.02em;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.dp-toggle-btn:first-child {
    border-right: none;
    border-radius: 999px 0 0 999px;
}

.dp-toggle-btn:last-child {
    border-left: 1px solid var(--dp-hero-pill-border);
    border-radius: 0 999px 999px 0;
}

.dp-toggle-btn--active {
    background: var(--dp-primary);
    color: var(--dp-on-primary);
    border-color: var(--dp-primary);
}

.dp-toggle-btn:last-child.dp-toggle-btn--active {
    border-left-color: var(--dp-primary);
}

.dp-toggle-btn:hover:not(.dp-toggle-btn--active) {
    background: rgba(255,255,255,0.15);
    color: var(--dp-hero-ink);
}

/* Collapsible category browse — collapsed by default (zero layout shift) */
.dp-category-reveal {
    margin-top: 0.85rem;
    text-align: center;
}
.dp-category-reveal__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.75rem;
    border: none;
    background: transparent;
    color: var(--dp-hero-ink);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    letter-spacing: 0.01em;
    transition: color 0.15s;
}
.dp-category-reveal__toggle:hover {
    color: var(--dp-link);
}
.dp-category-reveal__toggle i {
    font-size: 0.72rem;
    transition: transform 0.2s ease;
}
.dp-category-reveal.is-open .dp-category-reveal__toggle i {
    transform: rotate(180deg);
}
.dp-category-reveal__panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.25s ease;
}
.dp-category-reveal.is-open .dp-category-reveal__panel {
    grid-template-rows: 1fr;
}
.dp-category-reveal__panel-inner {
    overflow: hidden;
}
.dp-category-reveal .dp-category-chips {
    justify-content: center;
    padding-top: 0.85rem;
}

/* =====================================================
   Category chips — custom dp_category_chips shortcode
   ===================================================== */
.dp-category-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0.5rem 0 0;
}
.dp-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 17px;
    background: var(--dp-chip-bg);
    border: 1px solid var(--dp-chip-border);
    border-radius: 999px;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s;
    white-space: nowrap;
}
.dp-chip:hover {
    background: var(--dp-primary);
    border-color: var(--dp-primary);
}
.dp-chip__name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dp-chip-ink);
    line-height: 1;
}
.dp-chip:hover .dp-chip__name {
    color: var(--dp-on-primary);
}
.dp-chip__count {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--dp-chip-count-ink);
    background: var(--dp-chip-count-bg);
    border-radius: 999px;
    padding: 2px 8px;
    line-height: 1.4;
}
.dp-chip:hover .dp-chip__count {
    color: var(--dp-on-primary);
    background: rgba(255,255,255,0.22);
}

/* =====================================================
   DESIGN REFRESH (2026-06-10) — palette + component polish.
   All colors come from the :root tokens at the top of this
   file. !important is needed to beat the parent theme's
   customizer-generated styles.
   ===================================================== */

/* Theme buttons: token-driven. HivePress uses .button--primary (BEM); parent
   frontend.min.css loads after this file so these rules must target both names. */
.button--primary,
.button-primary,
.hp-form__button.button-primary,
button.button-primary,
button.button--primary {
    background-color: var(--dp-primary) !important;
    background-image: none !important;
    border-color: var(--dp-primary) !important;
    color: var(--dp-on-primary) !important;
    border-radius: var(--dp-radius-btn) !important;
    font-weight: 700 !important;
}
.button--primary:hover,
.button-primary:hover,
.hp-form__button.button-primary:hover,
button.button-primary:hover,
button.button--primary:hover {
    background-color: var(--dp-primary-dark) !important;
    border-color: var(--dp-primary-dark) !important;
}

/* "Add Listing" header button (theme renders it as button--secondary) */
.button--secondary,
button.button--secondary {
    background-color: var(--dp-primary) !important;
    border-color: var(--dp-primary) !important;
    color: var(--dp-on-primary) !important;
    border-radius: var(--dp-radius-btn) !important;
    font-weight: 700 !important;
}
.button--secondary:hover,
button.button--secondary:hover {
    background-color: var(--dp-primary-dark) !important;
    border-color: var(--dp-primary-dark) !important;
}

/* Listing cards: rounded, soft elevation instead of flat borders */
.hp-listing--view-block {
    border-radius: var(--dp-card-radius) !important;
    border: 1px solid var(--dp-card-border) !important;
    box-shadow: var(--dp-card-shadow) !important;
    overflow: hidden;
    transition: box-shadow 0.18s, transform 0.18s;
}
.hp-listing--view-block:hover {
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12) !important;
    transform: translateY(-2px);
}

/* Headings: tighter tracking for the new font + palette ink */
h1, h2, h3, h4, h5 {
    letter-spacing: -0.015em;
    color: var(--dp-ink);
}

/* Page background: warm off-white instead of stark white.
   !important: the parent's customizer-generated inline styles load after
   this file and would otherwise repaint white. */
body {
    background-color: var(--dp-bg-page) !important;
}

/* Inner-page title strips ("Messages", "About"…): sand tint instead of
   the parent's gray gradient */
.header-hero--title {
    background: var(--dp-bg-soft) !important;
}
.header-hero--title h1,
.header-hero--title h2 {
    color: var(--dp-ink) !important;
}

/* Footer: sand surface with a soft divider */
.site-footer {
    background-color: var(--dp-bg-soft);
    border-top: 1px solid var(--dp-divider);
}

/* Text links in content + footer follow the palette */
.page__text a:not(.button):not(.dp-chip),
.site-footer a,
.hp-listing__description a {
    color: var(--dp-link);
}

/* Listing card title links use heading ink (not the parent's gray-blue) */
.hp-listing__title a {
    color: var(--dp-ink);
}
.hp-listing__title a:hover {
    color: var(--dp-link);
}

/* HivePress accent icons (location pins, etc.): palette green instead of
   the theme's default mint */
.hp-listing__location i,
.hp-vendor__registered-date i,
.hp-listing__created-date i {
    color: var(--dp-primary);
}

/* =====================================================
   MARKETPLACE SIDE MARKERS (worker vs client)
   Tells "For hire" (talent offering) apart from "Wanted"
   (client posting a job) at a glance. Side is set server-side
   from the listing's root category (see includes/hivepress.php),
   so this is pure presentation — no JS, no layout shift.
   ===================================================== */

/* Coloured cap on the card, by side */
.hp-listing--view-block.dp-listing--forhire {
    border-top: 3px solid var(--dp-forhire-bar) !important;
}
.hp-listing--view-block.dp-listing--hiring {
    border-top: 3px solid var(--dp-hiring-bar) !important;
}

/* The pill that sits just above the listing title */
.dp-side-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.4;
    margin-bottom: 0.5rem;
}
.dp-side-badge i {
    font-size: 0.72rem;
}
.dp-side-badge--forhire {
    background: var(--dp-forhire-bar);
    color: var(--dp-forhire-ink);
}
.dp-side-badge--hiring {
    background: var(--dp-hiring-bar);
    color: var(--dp-hiring-ink);
}

/* =====================================================
   FEATURED LISTINGS — neutral, never coloured.
   Overrides the parent theme's amber treatment (which would
   clash with the coral "Wanted" marker). Featured = dark pill
   + star + lifted card, so it reads on a separate channel.
   ===================================================== */
.hp-listing--view-block.hp-listing--featured {
    /* Neutralise the parent's amber border on the sides/bottom only — the
       coloured top bar (the side marker) must always remain visible. */
    border-right-color: var(--dp-featured-border) !important;
    border-bottom-color: var(--dp-featured-border) !important;
    border-left-color: var(--dp-featured-border) !important;
    box-shadow: 0 10px 30px rgba(46, 71, 66, 0.16) !important;
}
/* Higher specificity than the parent's amber rules + !important so the neutral
   pill wins regardless of stylesheet load order. */
.hp-listing--view-block.hp-listing--featured .hp-listing__featured-badge,
.hp-listing--view-block .hp-listing__featured-badge {
    left: auto !important;
    right: 0.75rem !important;
    top: 0.75rem !important;
    width: auto !important;
    height: auto !important;
    padding: 4px 10px !important;
    border-radius: 999px !important;
    background-color: var(--dp-featured-pill) !important;
    background-image: none !important;
    color: #fff !important;
    gap: 5px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}
.hp-listing--view-block .hp-listing__featured-badge i {
    font-size: 11px;
}
.hp-listing__featured-label {
    line-height: 1.4;
}

/* =====================================================
   HEADER — give the top nav bar a defined surface so it
   reads as an intentional "shelf" instead of a blank
   white strip blending into the page. Crisp white +
   hairline border + soft shadow lifts it off the sand hero.
   ===================================================== */
.site-header .header-navbar {
    background: var(--dp-bg-soft);
    border-bottom: 1px solid var(--dp-divider);
    box-shadow: 0 1px 0 rgba(80, 30, 40, 0.04), 0 6px 18px rgba(80, 30, 40, 0.05);
}

/* =====================================================
   BRAND LOGO — no custom_logo is set, so the header renders
   the site-title text (.header-logo__name). Style it as the
   Dapperlance badge: wordmark on a rounded burgundy chip.
   The favicon / app icon (split-circle "D") is separate, set
   via wp_head in functions.php. The palette switcher swaps
   this for a preset badge live and restores it on reset.
   ===================================================== */
.header-logo__name {
    display: inline-block;
    background: var(--dp-primary);
    color: var(--dp-on-primary) !important;
    font-weight: 800;
    font-size: 1.3rem;
    letter-spacing: -0.02em;
    line-height: 1;
    padding: 0.42em 0.6em;
    border-radius: var(--dp-radius-btn);
}
.header-logo__description {
    display: none;
}

/* "Sign In" → ghost button so it pairs with the solid green
   "Add Listing" (button--secondary) instead of floating as bare text.
   Scoped to the DESKTOP header menu only; the mobile drawer copy
   keeps its plain menu-item styling. */
.site-header .header-navbar__menu .hp-menu__item--user-login.hp-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    padding: 0.5rem 1.15rem;
    border: 1.5px solid var(--dp-primary);
    border-radius: var(--dp-radius-btn);
    color: var(--dp-primary) !important;
    font-weight: 600;
    line-height: 1.2;
    transition: background-color 0.15s ease, color 0.15s ease;
}
.site-header .header-navbar__menu .hp-menu__item--user-login.hp-link:hover,
.site-header .header-navbar__menu .hp-menu__item--user-login.hp-link:focus {
    background-color: var(--dp-primary);
    color: #ffffff !important;
}

/* "Add Listing" is a WP header-menu item (so it shows in the MOBILE burger
   menu). On desktop the green Add Listing button already covers it, so hide
   the menu-item copy from the desktop nav only — the burger copy is unaffected. */
.header-navbar__menu .dp-menu-add {
    display: none;
}

/* =====================================================
   HERO SUBHEAD — one-line value prop under the H1,
   replacing the deleted "What is Dapperlance?" block.
   ===================================================== */
.dp-hero-subhead {
    margin: 0.5rem 0 1.6rem;
    max-width: 640px;
    font-size: 1.15rem;
    line-height: 1.5;
    font-weight: 500;
    color: var(--dp-hero-ink-muted);
}
@media (max-width: 768px) {
    .dp-hero-subhead {
        font-size: 1rem;
        margin-bottom: 1.25rem;
    }
}

/* =====================================================
   Listing-card placeholder — image-less listings render
   HivePress's grey placeholder SVG (/placeholders/…). We
   hide it and give the image area an on-brand gradient
   panel + a faint side icon (green talent / coral hiring).
   Pure CSS, keyed off the existing dp-listing--{side}
   class — no PHP, no per-listing data needed.
   ===================================================== */
.hp-listing__image a img[src*="/placeholders/"] {
    opacity: 0;
}
.hp-listing__image a:has(> img[src*="/placeholders/"]) {
    display: block;
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='%231e6a52' fill-opacity='0.38'%3E%3Ccircle cx='12' cy='8.5' r='4'/%3E%3Cpath d='M4 20.5c0-4.2 3.8-6.5 8-6.5s8 2.3 8 6.5z'/%3E%3C/g%3E%3C/svg%3E"),
        linear-gradient(135deg, var(--dp-forhire-bg) 0%, #f3f8f5 100%);
    background-repeat: no-repeat, no-repeat;
    background-position: center, center;
    background-size: 52px, cover;
}
.dp-listing--hiring .hp-listing__image a:has(> img[src*="/placeholders/"]) {
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='%239c2340' fill-opacity='0.38'%3E%3Crect x='3' y='8' width='18' height='11' rx='2'/%3E%3Cpath d='M9 8V6a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2' fill='none' stroke='%239c2340' stroke-opacity='0.38' stroke-width='2'/%3E%3C/g%3E%3C/svg%3E"),
        linear-gradient(135deg, var(--dp-hiring-bg) 0%, #faf2f3 100%);
}

/* =========================================================================
   FEATURED CREDITS — wallet dashboard ([dp_featured_credits]) + owner control
   on the single listing. Uses the burgundy brand tokens; self-contained.
   ========================================================================= */
.dp-fc { max-width: 760px; }
.dp-fc-wallet {
    display: flex; align-items: baseline; gap: .5rem;
    padding: 1rem 1.25rem; margin-bottom: .5rem;
    background: var(--dp-chip-bg); border: 1px solid var(--dp-chip-border);
    border-radius: var(--dp-card-radius);
}
.dp-fc-wallet__num { font-size: 2rem; font-weight: 800; color: var(--dp-primary); line-height: 1; }
.dp-fc-wallet__label { font-weight: 600; color: var(--dp-chip-ink); }
.dp-fc-help { color: var(--dp-hero-ink-muted); margin: .25rem 0 1.25rem; }
.dp-fc-subtitle { margin: 1.5rem 0 .75rem; font-size: 1.05rem; }

/* Buy bundles */
.dp-fc-bundles { display: flex; flex-wrap: wrap; gap: .75rem; }
.dp-fc-bundle {
    display: flex; flex-direction: column; gap: .15rem; min-width: 130px;
    padding: .85rem 1rem; text-decoration: none;
    background: #fff; border: 1px solid var(--dp-card-border);
    border-radius: var(--dp-card-radius); transition: border-color .15s, box-shadow .15s;
}
.dp-fc-bundle:hover { border-color: var(--dp-primary); box-shadow: var(--dp-card-shadow); }
.dp-fc-bundle__credits { font-weight: 800; color: var(--dp-primary); }
.dp-fc-bundle__price { color: var(--dp-hero-ink); font-weight: 600; }
.dp-fc-bundle__cta { font-size: .82rem; color: var(--dp-link); margin-top: .15rem; }

/* Listing rows */
.dp-fc-list { list-style: none; margin: 0; padding: 0; }
.dp-fc-item {
    display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
    padding: .85rem 0; border-bottom: 1px solid var(--dp-card-border);
}
.dp-fc-item__title { font-weight: 600; color: var(--dp-hero-ink); text-decoration: none; flex: 1 1 auto; }
.dp-fc-item__title:hover { color: var(--dp-primary); }
.dp-fc-tag { display: inline-flex; align-items: center; gap: .35rem; font-size: .85rem; font-weight: 600; white-space: nowrap; }
.dp-fc-tag--on   { color: #3a1820; }
.dp-fc-tag--on i { color: var(--dp-primary); }
.dp-fc-tag--sched { color: var(--dp-accent-pop); }
.dp-fc-tag--off  { color: var(--dp-hero-ink-muted); }

/* Feature form (shared) */
.dp-fc-form { display: flex; align-items: flex-end; gap: .6rem; flex-wrap: wrap; }
.dp-fc-form__date { display: flex; flex-direction: column; font-size: .78rem; color: var(--dp-hero-ink-muted); gap: .2rem; }
.dp-fc-form__date input { padding: .4rem .5rem; border: 1px solid var(--dp-card-border); border-radius: var(--dp-radius-btn); }
.dp-fc-btn { display: inline-flex; align-items: center; gap: .4rem; }

/* Notices */
.dp-fc-notice { padding: .7rem 1rem; border-radius: var(--dp-radius-btn); margin-bottom: 1rem; font-weight: 600; }
.dp-fc-notice--success { background: var(--dp-forhire-bg); color: #155245; border: 1px solid #bcdfd2; }
.dp-fc-notice--error   { background: var(--dp-hiring-bg);  color: #8a2540; border: 1px solid #f1c4cf; }
.dp-fc-empty { color: var(--dp-hero-ink-muted); }

/* Owner control on the single listing page */
.dp-fc-owner {
    margin-top: 1rem; padding: 1rem 1.15rem;
    background: var(--dp-chip-bg); border: 1px solid var(--dp-chip-border);
    border-radius: var(--dp-card-radius);
}
.dp-fc-owner__head { font-weight: 700; color: var(--dp-chip-ink); margin-bottom: .6rem; display: flex; align-items: center; gap: .4rem; }
.dp-fc-owner__head i { color: var(--dp-primary); }
