/* ============================================================
   Drughelp Directories – Public Styles
   ============================================================ */

/* Variables */
:root {
    --dh-primary:    #2c6fad;
    --dh-secondary:  #e74c3c;
    --dh-bg:         #f8f9fa;
    --dh-border:     #dee2e6;
    --dh-text:       #333;
    --dh-radius:     6px;
}

/* ============================================================
   Virtual-page wrapper
   ============================================================ */
/* Isolates the plugin's virtual pages (state, city, facility, treatment) from
   theme-level padding/margin on .entry-content that can push content ~3% off-
   screen. overflow-x is intentionally omitted here so that the full-bleed
   .dh-intro-band--full-width (which uses negative margin + 100vw) can break
   out of any fixed-width theme container. Scrollbar suppression is handled by
   the body-level overflow rule below when a full-width band is present. */
.dh-page-wrap {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Suppress any horizontal scrollbar that the full-bleed intro band might
   otherwise create when a narrower theme container is in use. */
body.dh-has-full-width-band {
    overflow-x: hidden;
}

/* ============================================================
   US Map
   ============================================================ */
.dh-map-container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto 30px;
}

.dh-map-container svg {
    width: 100%;
    height: auto;
    display: block;
}

.dh-us-map path,
.dh-us-map rect.state {
    fill: var(--dh-primary);
    stroke: #fff;
    stroke-width: 1px;
    cursor: pointer;
    transition: fill 0.2s ease;
}

.dh-us-map path:hover,
.dh-us-map rect.state:hover {
    fill: var(--dh-secondary);
}

/* State abbreviation labels */
.dh-state-label {
    font-family: sans-serif;
    font-size: 7px;
    fill: #fff;
    text-anchor: middle;
    dominant-baseline: middle;
    pointer-events: none;
    font-weight: 700;
    letter-spacing: 0.02em;
}

/* Map tip text below the SVG */
.dh-map-tip {
    text-align: center;
    font-size: .85rem;
    color: #888;
    margin-top: 6px;
}

/* ============================================================
   Map + state sidebar layout
   ============================================================ */

/* Wrapper: sidebar on left, map on right */
.dh-map-with-sidebar {
    display: flex;
    align-items: stretch;
    gap: 12px;
    margin-bottom: 30px;
    position: relative;
}

/* State sidebar */
.dh-state-sidebar {
    flex: 0 0 175px;
    width: 175px;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    background: #fff;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}

/* Sidebar heading */
.dh-state-sidebar-header {
    flex-shrink: 0;
    margin: 0;
    padding: 10px 12px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fff;
    background: var(--dh-primary);
}

.dh-state-list {
    list-style: none;
    margin: 0;
    padding: 6px 0;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--dh-primary) #eee;
}

.dh-state-list::-webkit-scrollbar {
    width: 5px;
}

.dh-state-list::-webkit-scrollbar-track {
    background: #eee;
}

.dh-state-list::-webkit-scrollbar-thumb {
    background-color: var(--dh-primary);
    border-radius: 3px;
}

.dh-state-list a {
    display: block;
    margin: 1px 6px;
    padding: 6px 10px;
    font-size: 0.84rem;
    color: var(--dh-text);
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dh-state-list a:hover {
    background: var(--dh-primary);
    color: #fff;
}

/* Map takes the remaining width */
.dh-map-with-sidebar .dh-map-container {
    flex: 1;
    min-width: 0;
    margin: 0;
    border-radius: var(--dh-radius);
    overflow: hidden;
    padding: 8px;
    box-sizing: border-box;
}

/* ============================================================
   Compact small-state panel (right of map)
   ============================================================ */
/* Compact NE panel is vertically aligned to start near the NH/VT/ME region */
.dh-compact-states-panel {
    flex: 0 0 68px;
    width: 68px;
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: flex-start;
    gap: 6px;
    padding-top: 90px;
}

.dh-compact-states-label {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #999;
    margin: 0 0 2px;
    text-align: center;
    white-space: nowrap;
}

.dh-compact-states-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    width: 100%;
}

.dh-compact-state-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: var(--dh-primary);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    border: 1px solid var(--dh-primary);
    border-radius: 5px;
    text-decoration: none;
    transition: background 0.15s, color 0.15s, transform 0.1s;
    cursor: pointer;
}

.dh-compact-state-btn:hover,
.dh-compact-state-btn:focus,
.dh-compact-state-btn.dh-is-hovered {
    background: #fff;
    color: var(--dh-primary);
    transform: scale(1.08);
    text-decoration: none;
}

/* SVG path highlight triggered by hovering the compact NE button */
.dh-state-path.dh-is-hovered {
    fill: var(--dh-secondary);
}



.dh-state-dropdown-wrap {
    display: none;
}

/* ============================================================
   States grid on main page (legacy – kept for back-compat)
   ============================================================ */
.dh-states-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
    margin: 24px 0;
}

.dh-state-card {
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 14px 12px;
    text-align: center;
    text-decoration: none;
    color: var(--dh-text);
    transition: box-shadow 0.2s, transform 0.15s;
    display: block;
}

.dh-state-card:hover {
    box-shadow: 0 4px 14px rgba(0,0,0,.12);
    transform: translateY(-2px);
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-state-card img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 8px;
}

.dh-state-card .dh-state-abbr {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--dh-primary);
    line-height: 1;
    display: block;
    margin-bottom: 4px;
}

.dh-state-card .dh-state-name {
    font-size: 0.85rem;
    color: #555;
}

/* ============================================================
   Search Widget
   ============================================================ */
.dh-search-widget {
    background: var(--dh-bg);
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 10px 14px;
    margin-bottom: 30px;
}

/* Outer form: single flex row on desktop */
.dh-search-form {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    align-items: center;
}

/* Location group (State / City / ZIP) */
.dh-search-location {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    flex: 3;
    min-width: 0;
}

/* Filters group (Treatment / Insurance / button) */
.dh-search-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    flex: 2;
    min-width: 0;
}

.dh-search-field {
    flex: 1;
    min-width: 0;
}

.dh-search-field input,
.dh-search-field select {
    width: 100%;
    padding: 0 10px;
    height: 38px;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    font-size: 0.9rem;
    background: #fff;
    box-sizing: border-box;
}

/* ZIP field is narrower on desktop */
.dh-field-zip {
    flex: 0 0 100px;
}

/* City field hidden until state selected */
.dh-field-city {
    display: none;
    flex: 1;
    min-width: 0;
}

.dh-field-city.is-visible {
    display: block;
}

/* Icon-only search button */
.dh-search-btn {
    background: var(--dh-primary);
    color: #fff;
    border: none;
    width: 38px;
    height: 38px;
    border-radius: var(--dh-radius);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
    padding: 0;
}

.dh-search-btn:hover {
    background: #1a5591;
}

.dh-search-reset {
    font-size: 12px;
    color: #666;
    text-decoration: none;
    align-self: center;
    padding: 0 4px;
    white-space: nowrap;
    line-height: 38px;
}

.dh-search-reset:hover {
    color: #c0392b;
    text-decoration: underline;
}

/* ============================================================
   Search Widget – Mobile responsive (≤ 640 px)
   ============================================================ */
@media (max-width: 640px) {
    /* Stack the two groups vertically */
    .dh-search-form {
        flex-wrap: wrap;
    }

    .dh-search-location {
        flex: 0 0 100%;
        flex-wrap: wrap;
    }

    .dh-search-filters {
        flex: 0 0 100%;
    }

    /*
     * Each location field takes exactly half the row so that:
     *   - No state selected  → [State][ZIP]
     *   - State selected     → [State][City] / [ZIP] (ZIP wraps to its own row)
     */
    .dh-field-state,
    .dh-field-city,
    .dh-field-zip {
        flex: 0 0 calc(50% - 4px);
        max-width: calc(50% - 4px);
    }

    /* Treatment/Insurance each share the filters row; button stays at far right */
    .dh-search-filters .dh-search-field {
        flex: 1;
        min-width: 0;
    }
}

/* ============================================================
   Facilities list
   ============================================================ */
/* ============================================================
   Facility list grid + card
   ============================================================ */

/* Grid container — columns driven by PHP-injected --dh-cols CSS variable.
   Default: 3 columns.  PHP clamps the value to min(configured, card_count)
   so a row is never left with phantom empty cells. */
.dh-facilities-list {
    display: grid;
    grid-template-columns: repeat(var(--dh-cols, 3), 1fr);
    gap: 24px;
    margin: 20px 0;
}

/* ── Card shell ─────────────────────────────────────────────────────────── */
.dh-facility-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: 12px;
    overflow: hidden;
    color: var(--dh-text);
    transition: box-shadow 0.2s, transform 0.2s;
}

.dh-facility-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,.13);
    transform: translateY(-2px);
}

.dh-facility-card.featured {
    border: 2px solid #f39c12;
}

/* ── Image gallery strip (top of card) ─────────────────────────────────── */
.dh-fac-card-gallery {
    display: grid;
    overflow: hidden;
    height: 200px;
    flex-shrink: 0;
    gap: 2px;
    background: #e0e0e0;
    text-decoration: none;
}

/* Number of images = 1 */
.dh-fac-card-gallery--1 {
    grid-template-columns: 1fr;
}

/* Number of images = 2 */
.dh-fac-card-gallery--2 {
    grid-template-columns: 1fr 1fr;
}

/* Number of images = 3 — first column ~60% wide to match the design reference
   (wide hero image left, two smaller images stacked on the right). */
.dh-fac-card-gallery--3 {
    grid-template-columns: 1.6fr 1fr 1fr;
}

.dh-fac-card-img-slot {
    overflow: hidden;
    position: relative;
}

.dh-fac-card-img-slot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Placeholder slot when there is no image */
.dh-fac-card-no-img {
    background: #e9ecef;
}

/* Primary treatment badge on the main (first) image slot */
.dh-fac-card-gallery .dh-card-type-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(255,255,255,0.92);
    color: var(--dh-text);
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 4px;
    z-index: 1;
    pointer-events: none;
    max-width: calc(100% - 20px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Card body ──────────────────────────────────────────────────────────── */
.dh-fac-card-body {
    padding: 15px 18px 10px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.dh-fac-card-body .dh-facility-location {
    font-size: 0.82rem;
    color: #888;
    margin: 0 0 3px;
}

.dh-fac-card-body h3 {
    margin: 0 0 6px;
    font-size: 1.05rem;
    color: var(--dh-primary);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
}

.dh-fac-card-body h3 a {
    color: inherit;
    text-decoration: none;
}

.dh-fac-card-body h3 a:hover {
    text-decoration: underline;
}

.dh-fac-card-body .dh-rating-row {
    flex-wrap: wrap;
    margin: 3px 0 5px;
}

.dh-fac-card-body .dh-treatment-tags {
    margin: 5px 0 6px;
}

.dh-fac-card-body .dh-facility-excerpt {
    font-size: 0.85rem;
    color: #555;
    line-height: 1.5;
    margin: 5px 0 6px;
    flex: 1;        /* push amenities + phone to the bottom */
}

.dh-excerpt-more {
    font-weight: 600;
    color: var(--dh-primary);
    text-decoration: none;
    margin-left: 3px;
}

.dh-excerpt-more:hover {
    text-decoration: underline;
}

.dh-fac-card-body .dh-amenities-list {
    margin: 4px 0 0;
}

/* ── Action buttons bar ─────────────────────────────────────────────────── */
.dh-fac-card-actions {
    display: flex;
    gap: 10px;
    padding: 11px 18px 15px;
    border-top: 1px solid var(--dh-border);
}

.dh-fac-card-view-btn,
.dh-fac-card-msg-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 18px;
    border-radius: 20px;
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    cursor: pointer;
    border: 1px solid;
    background: none;
    font-family: inherit;
    line-height: 1.4;
}

.dh-fac-card-view-btn {
    background: #f0f4ff;
    color: var(--dh-primary);
    border-color: #c8d4ff;
}

.dh-fac-card-view-btn:hover {
    background: var(--dh-primary);
    color: #fff;
    border-color: var(--dh-primary);
}

.dh-fac-card-msg-btn {
    background: #fff;
    color: var(--dh-text);
    border-color: var(--dh-border);
}

.dh-fac-card-msg-btn:hover {
    background: #f5f5f5;
}

/* ── Legacy single-column list styles (kept for backward compat) ─────────
   These classes are no longer emitted by facility-list.php but may be used
   by custom themes or legacy partials that include the old markup.         */
.dh-facility-info {
    flex: 1;
    min-width: 0;
}

.dh-facility-info h3 {
    margin: 0 0 6px;
    font-size: 1.05rem;
    color: var(--dh-primary);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
}

.dh-facility-info h3 a {
    color: inherit;
    text-decoration: none;
}

.dh-facility-info h3 a:hover {
    text-decoration: underline;
}

.dh-facility-meta {
    font-size: 0.85rem;
    color: #666;
    margin: 4px 0;
}

.dh-facility-meta svg {
    width: 14px;
    height: 14px;
    vertical-align: middle;
    margin-right: 4px;
}

.dh-facility-excerpt {
    font-size: 0.85rem;
    color: #555;
    margin: 6px 0;
    line-height: 1.5;
}

.dh-badge {
    display: inline-block;
    background: #e3f2fd;
    color: #1565c0;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
    margin: 2px;
}

.dh-badge-featured {
    background: #fff8e1;
    color: #f57f17;
}

/* ============================================================
   Enhanced facility card — supplemental rules
   ============================================================ */

/* Facility location line */
.dh-facility-location {
    font-size: 0.82rem;
    color: #888;
    margin: 0 0 4px;
}

/* Verified / featured checkmark badge */
.dh-verified-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background: var(--dh-primary);
    color: #fff;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    margin-left: 5px;
    vertical-align: middle;
}

/* Card thumbnail type badge (legacy — kept for backward compat) */
.dh-facility-thumb {
    position: relative;
}

.dh-card-type-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(255,255,255,0.92);
    color: var(--dh-text);
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    z-index: 1;
    pointer-events: none;
}

/* Star rating row */
.dh-rating-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 4px 0 6px;
}

.dh-stars {
    display: inline-flex;
    gap: 1px;
    font-size: 1rem;
    line-height: 1;
}

.dh-star-full {
    color: #f4a623;
}

.dh-star-half {
    color: #f4a623;
    font-size: 0.85rem;
}

.dh-star-empty {
    color: #ccc;
}

.dh-rating-count {
    font-size: 0.8rem;
    color: #666;
}

/* Accreditation badges row */
.dh-accreditations {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin: 5px 0;
}

.dh-accred-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
}

/* Treatment type tags */
.dh-treatment-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 6px 0;
}

.dh-tag {
    background: #f0f4ff;
    color: #3b5bdb;
    border: 1px solid #d0d9ff;
    padding: 2px 9px;
    border-radius: 12px;
    font-size: 0.75rem;
    white-space: nowrap;
}

/* Short description excerpt */
.dh-facility-excerpt {
    font-size: 0.85rem;
    color: #555;
    margin: 6px 0;
    line-height: 1.5;
}

/* Amenities list */
.dh-amenities-list {
    list-style: none;
    padding: 0;
    margin: 6px 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
}

.dh-amenity-item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.82rem;
    color: #444;
}

.dh-amenity-icon {
    font-size: 1rem;
    line-height: 1;
}


.dh-city-search-bar {
    display: flex;
    gap: 8px;
    margin: 16px 0;
}

.dh-city-search-bar input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
}

.dh-alphabet-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 16px 0;
}

.dh-alpha-btn {
    background: var(--dh-bg);
    border: 1px solid var(--dh-border);
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    transition: background 0.2s;
}

.dh-alpha-btn:hover,
.dh-alpha-btn.active {
    background: var(--dh-primary);
    color: #fff;
    border-color: var(--dh-primary);
}

.dh-cities-dropdown select {
    width: 100%;
    max-width: 400px;
    padding: 8px 12px;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    font-size: 0.95rem;
}

.dh-city-group {
    margin-bottom: 14px;
}

.dh-city-group h4 {
    font-size: 0.9rem;
    color: #888;
    border-bottom: 1px solid var(--dh-border);
    padding-bottom: 4px;
    margin: 0 0 8px;
}

.dh-city-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 0;
    list-style: none;
}

.dh-city-list a {
    background: #fff;
    border: 1px solid var(--dh-border);
    padding: 4px 12px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.9rem;
    color: var(--dh-primary);
    transition: background 0.2s;
}

.dh-city-list a:hover {
    background: var(--dh-primary);
    color: #fff;
}

/* ============================================================
   Single facility page
   ============================================================ */
.dh-facility-single {
    max-width: 860px;
    margin: 0 auto;
}

.dh-facility-header {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
}

.dh-facility-header img {
    max-width: 300px;
    border-radius: var(--dh-radius);
    object-fit: cover;
}

.dh-facility-header-info h1 {
    margin: 0 0 8px;
}

.dh-breadcrumb {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 16px;
}

.dh-breadcrumb a {
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-info-row {
    display: flex;
    gap: 8px;
    margin: 6px 0;
    align-items: center;
    font-size: 0.95rem;
}

.dh-info-label {
    font-weight: 600;
    min-width: 120px;
}

.dh-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.dh-section-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 24px 0 12px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--dh-primary);
}

/* ============================================================
   Featured widget
   ============================================================ */
.dh-featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    margin: 16px 0;
}

.dh-featured-card {
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--dh-text);
    transition: box-shadow 0.2s, transform 0.15s;
    display: block;
}

.dh-featured-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,.12);
    transform: translateY(-3px);
    text-decoration: none;
}

.dh-featured-card img {
    width: 100%;
    height: 140px;
    object-fit: cover;
}

.dh-featured-card .dh-no-img {
    width: 100%;
    height: 140px;
    background: linear-gradient(135deg, var(--dh-primary), #1a5591);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,.6);
    font-size: 0.85rem;
}

.dh-featured-card-body {
    padding: 12px;
}

.dh-featured-card-body h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    color: var(--dh-primary);
}

.dh-featured-card-body .dh-location {
    font-size: 0.8rem;
    color: #888;
}

/* ============================================================
   Treatments widget
   ============================================================ */
.dh-treatments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 14px;
    margin: 16px 0;
}

.dh-treatment-card {
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 16px;
    text-align: center;
    text-decoration: none;
    color: var(--dh-text);
    transition: box-shadow 0.2s;
    display: block;
}

.dh-treatment-card:hover {
    box-shadow: 0 4px 14px rgba(0,0,0,.1);
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-treatment-card img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    margin-bottom: 10px;
}

.dh-treatment-card h3 {
    margin: 0;
    font-size: 0.95rem;
}

/* ============================================================
   Insurance Grid Widget
   ============================================================ */
.dh-insurance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
    margin: 16px 0;
}

.dh-insurance-card {
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 16px;
    text-align: center;
    text-decoration: none;
    color: var(--dh-text);
    transition: box-shadow 0.2s, border-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 90px;
}

.dh-insurance-card:hover {
    box-shadow: 0 4px 14px rgba(0,0,0,.1);
    border-color: var(--dh-primary);
    text-decoration: none;
    color: var(--dh-primary);
}

.dh-insurance-card img {
    max-width: 120px;
    max-height: 60px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.2s;
}

.dh-insurance-card:hover img {
    filter: grayscale(0%);
}

.dh-insurance-card-name {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
}

/* Insurance detail page */
.dh-insurance-page .dh-insurance-heading {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
}

.dh-insurance-page .dh-insurance-icon img.dh-ins-page-logo {
    height: 80px;
    width: auto;
}

.dh-insurance-page .dh-insurance-heading h1 {
    margin: 0;
}

.dh-insurance-page .dh-insurance-description {
    margin-top: 12px;
    font-size: 1rem;
    line-height: 1.6;
}

.dh-insurance-state-filter {
    margin: 20px 0;
}

/* ============================================================
   Pagination
   ============================================================ */
.dh-pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin: 24px 0;
    flex-wrap: wrap;
}

.dh-pagination a,
.dh-pagination span {
    padding: 6px 14px;
    border: 1px solid var(--dh-border);
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    color: var(--dh-primary);
}

.dh-pagination span.current {
    background: var(--dh-primary);
    color: #fff;
    border-color: var(--dh-primary);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 600px) {
    /* Hide the sidebar on mobile */
    .dh-state-sidebar {
        display: none;
    }

    /* Show the mobile dropdown above the map */
    .dh-state-dropdown-wrap {
        display: block;
        margin-bottom: 12px;
    }

    .dh-state-dropdown {
        width: 100%;
        padding: 10px 12px;
        border: 1px solid var(--dh-border);
        border-radius: var(--dh-radius);
        font-size: 0.95rem;
        background: #fff;
        cursor: pointer;
    }

    /* Full-width map on mobile */
    .dh-map-with-sidebar {
        flex-direction: column;
    }

    .dh-map-with-sidebar .dh-map-container {
        border-radius: var(--dh-radius);
        border: 1px solid var(--dh-border);
        width: 100%;
    }

    /* Hide compact state panel on mobile (states are in dropdown) */
    .dh-compact-states-panel {
        display: none;
    }

    .dh-facility-card {
        flex-direction: column;
    }
    /* Responsive grid: tablet (>600px) caps at 2 columns */
}

@media (min-width: 601px) and (max-width: 900px) {
    .dh-facilities-list {
        /* Cap at 2 columns on tablet. min() also preserves a 1-column admin
           setting so narrower pages don't forcibly go to 2. */
        grid-template-columns: repeat(min(var(--dh-cols, 2), 2), 1fr);
    }
}

@media (max-width: 600px) {
    .dh-facilities-list {
        /* Single column on mobile. */
        grid-template-columns: 1fr;
    }
    .dh-search-form {
        flex-direction: column;
    }
    .dh-search-field {
        min-width: unset;
    }
}

/* ============================================================
   State cities widget  [drughelp_state] shortcode
   ============================================================ */
.dh-state-cities-widget {
    margin: 20px 0;
}

.dh-scw-heading {
    font-size: 1.3rem;
    margin: 0 0 14px;
}

.dh-scw-heading a {
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-scw-heading a:hover {
    text-decoration: underline;
}

/* ============================================================
   City facilities widget  [drughelp_city] shortcode
   ============================================================ */
.dh-city-facilities-widget {
    margin: 20px 0;
}

.dh-cfw-heading {
    font-size: 1.3rem;
    margin: 0 0 14px;
}

.dh-cfw-heading a {
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-cfw-heading a:hover {
    text-decoration: underline;
}

/* ============================================================
   Facility map embed
   ============================================================ */
.dh-facility-map {
    margin: 0 0 24px;
    line-height: 0;
}

.dh-facility-map iframe {
    width: 100%;
    max-width: 100%;
    height: 400px;
    border: 0;
    border-radius: var(--dh-radius);
    display: block;
}

/* ============================================================
   Default layout: two-column hero (heading + intro | image)
   ============================================================ */

.dh-default-hero {
    display: flex;
    align-items: flex-start;
    gap: 32px;
    margin: 0 0 32px;
    padding: 24px 0;
}

.dh-default-hero-content {
    flex: 1 1 55%;
}

.dh-default-hero-content h1 {
    font-size: 2rem;
    line-height: 1.2;
    margin: 0 0 16px;
    color: var(--dh-text);
}

.dh-default-intro {
    font-size: 0.97rem;
    line-height: 1.65;
    color: #555;
}

.dh-default-intro p {
    margin: 0 0 12px;
}

.dh-default-hero-image {
    flex: 0 0 40%;
    max-width: 40%;
}

.dh-default-hero-image img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: cover;
    border-radius: var(--dh-radius);
    display: block;
}

@media (max-width: 700px) {
    .dh-default-hero {
        flex-direction: column;
    }
    .dh-default-hero-image {
        flex: none;
        max-width: 100%;
        width: 100%;
    }
}

/* ============================================================
   Intro band — full-width teal strip below the hero
   ============================================================ */

.dh-intro-band {
    background: #E8F5F0;
    border-top: 3px solid #3A9A7A;
    border-bottom: 3px solid #3A9A7A;
    padding: 36px 20px;
    margin: 0 0 36px;
}

/* Full-width (full-bleed) variant: breaks out of any fixed-width theme container */
.dh-intro-band--full-width {
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    max-width: 100vw;
    box-sizing: border-box;
}

.dh-intro-band-inner {
    max-width: 820px;
    margin: 0 auto;
    text-align: center;
    color: #2A5A45;
    font-size: 0.97rem;
    line-height: 1.72;
}

.dh-intro-band-inner p {
    margin: 0 0 14px;
}

.dh-intro-band-inner p:last-child {
    margin-bottom: 0;
}

.dh-intro-band-inner a {
    color: #1E7A5E;
    text-decoration: underline;
}

/* ============================================================
   HOW IT WORKS — shown on default state/city pages
   ============================================================ */

.dh-how-it-works {
    background: #fff;
    border: none;
    border-radius: 0;
    padding: 50px 24px;
    margin: 0;
    text-align: center;
    /* Full-bleed: break out of any fixed-width theme container */
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    max-width: 100vw;
    box-sizing: border-box;
}

.dh-how-it-works h2 {
    font-size: 1.6rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    margin: 0 0 28px;
    color: var(--dh-text);
}

.dh-hiw-steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.dh-hiw-step {
    flex: 0 1 180px;
    text-align: center;
}

.dh-hiw-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 10px;
    background: var(--dh-primary);
    color: #fff;
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.dh-hiw-step h3 {
    font-size: 1.05rem;
    margin: 0 0 6px;
    color: var(--dh-text);
}

.dh-hiw-step p {
    font-size: 0.88rem;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

.dh-hiw-arrow {
    font-size: 1.8rem;
    color: var(--dh-primary);
    align-self: center;
    padding-bottom: 30px;
}

@media (max-width: 600px) {
    .dh-hiw-arrow {
        display: none;
    }
    .dh-hiw-steps {
        gap: 24px;
    }
}

/* ============================================================
   Insurance Coverage section
   ============================================================ */

.dh-insurance-section {
    text-align: center;
    padding: 50px 24px;
    margin: 0;
    border: none;
    border-radius: 0;
    background: #f4f4f4;
    /* Full-bleed: break out of any fixed-width theme container */
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    max-width: 100vw;
    box-sizing: border-box;
}

.dh-insurance-heading {
    font-size: 1.9rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin: 0 0 6px;
    color: var(--dh-text);
}

.dh-ins-subtitle {
    font-size: 1.05rem;
    color: #666;
    margin: 0 0 28px;
}

.dh-insurance-logos {
    /* Legacy selector kept for backward compat — carousel supersedes this. */
    display: none;
}

.dh-ins-carousel {
    position: relative;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    margin: 0 0 34px;
}

.dh-ins-viewport {
    overflow: hidden;
    flex: 1;
    min-width: 0;
}

.dh-ins-track {
    display: flex;
    flex-direction: row;
    align-items: center;
    transition: transform 0.35s ease;
    will-change: transform;
}

.dh-insurance-logo-item {
    flex: 0 0 auto;
    padding: 8px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dh-insurance-logo-item a {
    display: block;
    text-decoration: none;
}

.dh-ins-logo {
    /* Height is set via inline style from PHP (configurable in admin).    */
    /* Width is intentionally left as auto to preserve the original ratio. */
    width: auto;
    max-width: 160px;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.2s;
    display: block;
}

.dh-ins-logo:hover {
    filter: grayscale(0%);
}

.dh-ins-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #444;
    letter-spacing: .03em;
    white-space: nowrap;
}

.dh-ins-carousel-btn {
    flex: 0 0 36px;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--dh-primary, #2d8b57);
    background: #fff;
    color: var(--dh-primary, #2d8b57);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    transition: background 0.2s, color 0.2s;
    padding: 0;
}

.dh-ins-carousel-btn:hover {
    background: var(--dh-primary, #2d8b57);
    color: #fff;
}

.dh-ins-carousel-btn:disabled {
    opacity: 0.3;
    cursor: default;
}

.dh-insurance-cta {
    display: inline-block;
    background: #E07020;
    color: #fff;
    font-size: 0.97rem;
    font-weight: 700;
    letter-spacing: .05em;
    padding: 14px 38px;
    border-radius: 4px;
    text-decoration: none;
    text-transform: uppercase;
    transition: background 0.2s;
    border: none;
    cursor: pointer;
}

.dh-insurance-cta:hover,
.dh-insurance-cta:focus {
    background: #C05C10;
    color: #fff;
    text-decoration: none;
}

/* ============================================================
   City Browser — full-bleed row with no top/bottom margin
   ============================================================ */

.dh-city-browser {
    /* Full-bleed: break out of any fixed-width theme container */
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    max-width: 100vw;
    box-sizing: border-box;
    margin-top: 0;
    margin-bottom: 0;
    padding: 36px 24px;
}

.dh-city-browser-title {
    text-align: center;
    font-size: 1.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--dh-primary);
    margin: 0 0 20px;
}

/* ============================================================
   Facility Center Overview grid — shown on default layout
   ============================================================ */

.dh-center-overview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
    margin: 16px 0 28px;
}

.dh-overview-item {
    background: var(--dh-bg);
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dh-overview-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #888;
    font-weight: 600;
}

.dh-overview-value {
    font-size: 0.95rem;
    color: var(--dh-text);
    line-height: 1.45;
}

.dh-overview-value a {
    color: var(--dh-primary);
    text-decoration: none;
}

.dh-overview-value a:hover {
    text-decoration: underline;
}

/* ============================================================
   Custom State layout — WPBakery content wrapper
   ============================================================
   Ensure the description wrapper never clips WPBakery content
   (e.g. stretched rows that use negative margins to escape their
   container).  overflow: visible is the CSS default for block
   elements, but some themes / resets override it; declaring it
   explicitly here guarantees our wrapper is never the clipping
   boundary for WPBakery stretched rows.
   ============================================================ */
.dh-state-description {
    overflow: visible;
}

/* ============================================================
   WPBakery column/row layout — self-contained grid
   ============================================================
   These rules replicate the essential layout CSS from WPBakery's
   js_composer_front.css, scoped to the .wpb-js-composer wrapper
   that render_description() writes around WPBakery-rendered content.

   This guarantees that multi-column WPBakery layouts work on
   virtual facility/city/state pages regardless of whether
   WPBakery's own stylesheet is enqueued.  The rules are harmless
   on pages where WPBakery's CSS is also loaded — they are
   identical in behaviour.
   ============================================================ */

/* Row: negative-margin gutter container + clearfix */
.wpb-js-composer .vc_row {
    margin-left:  -15px;
    margin-right: -15px;
}
.wpb-js-composer .vc_row::before,
.wpb-js-composer .vc_row::after {
    content: " ";
    display: table;
}
.wpb-js-composer .vc_row::after {
    clear: both;
}

/* Stretched rows: reset the gutter margins so WPBakery's stretch JS measures
   the row's natural position (relative to the viewport) without our -15px
   offset, then applies the correct full-viewport negative margin-left.
   Without this, the stretch lands ~15 px from the left edge instead of 0 px,
   and on themes with overflow:hidden the gap appears as the full container
   indent (~193 px). The inline styles set by WPBakery's JS override this rule,
   so the reset only affects the initial measurement pass. */
.wpb-js-composer .vc_row[data-vc-full-width="true"] {
    margin-left: 0;
    margin-right: 0;
}

/* Column base: float + gutter padding */
.wpb-js-composer [class*="vc_col-sm-"],
.wpb-js-composer [class*="vc_col-md-"],
.wpb-js-composer [class*="vc_col-lg-"],
.wpb-js-composer [class*="vc_col-xs-"] {
    position:    relative;
    float:       left;
    min-height:  1px;
    padding-left:  15px;
    padding-right: 15px;
    box-sizing:  border-box;
}

/* 12-column sm widths (desktop / tablet landscape) */
.wpb-js-composer .vc_col-sm-1  { width:  8.3333%; }
.wpb-js-composer .vc_col-sm-2  { width: 16.6667%; }
.wpb-js-composer .vc_col-sm-3  { width: 25%;      }
.wpb-js-composer .vc_col-sm-4  { width: 33.3333%; }
.wpb-js-composer .vc_col-sm-5  { width: 41.6667%; }
.wpb-js-composer .vc_col-sm-6  { width: 50%;      }
.wpb-js-composer .vc_col-sm-7  { width: 58.3333%; }
.wpb-js-composer .vc_col-sm-8  { width: 66.6667%; }
.wpb-js-composer .vc_col-sm-9  { width: 75%;      }
.wpb-js-composer .vc_col-sm-10 { width: 83.3333%; }
.wpb-js-composer .vc_col-sm-11 { width: 91.6667%; }
.wpb-js-composer .vc_col-sm-12 { width: 100%;     }

/* md widths override sm on wider viewports */
.wpb-js-composer .vc_col-md-1  { width:  8.3333%; }
.wpb-js-composer .vc_col-md-2  { width: 16.6667%; }
.wpb-js-composer .vc_col-md-3  { width: 25%;      }
.wpb-js-composer .vc_col-md-4  { width: 33.3333%; }
.wpb-js-composer .vc_col-md-5  { width: 41.6667%; }
.wpb-js-composer .vc_col-md-6  { width: 50%;      }
.wpb-js-composer .vc_col-md-7  { width: 58.3333%; }
.wpb-js-composer .vc_col-md-8  { width: 66.6667%; }
.wpb-js-composer .vc_col-md-9  { width: 75%;      }
.wpb-js-composer .vc_col-md-10 { width: 83.3333%; }
.wpb-js-composer .vc_col-md-11 { width: 91.6667%; }
.wpb-js-composer .vc_col-md-12 { width: 100%;     }

/* Offset helpers */
.wpb-js-composer .vc_col-sm-offset-0  { margin-left: 0;       }
.wpb-js-composer .vc_col-sm-offset-1  { margin-left:  8.3333%; }
.wpb-js-composer .vc_col-sm-offset-2  { margin-left: 16.6667%; }
.wpb-js-composer .vc_col-sm-offset-3  { margin-left: 25%;      }
.wpb-js-composer .vc_col-sm-offset-4  { margin-left: 33.3333%; }
.wpb-js-composer .vc_col-sm-offset-5  { margin-left: 41.6667%; }
.wpb-js-composer .vc_col-sm-offset-6  { margin-left: 50%;      }

/* Responsive: stack all columns below 768px */
@media (max-width: 767px) {
    .wpb-js-composer [class*="vc_col-sm-"],
    .wpb-js-composer [class*="vc_col-md-"],
    .wpb-js-composer [class*="vc_col-lg-"],
    .wpb-js-composer [class*="vc_col-xs-"] {
        float: none;
        width: 100%;
    }
}

/* Row: full-height (viewport) */
.wpb-js-composer .vc_row.vc_row-full-height,
.wpb-js-composer .vc_row.vc_row-o-full-height {
    min-height: 100vh;
}

/* Row: equal-height columns — flex container */
.wpb-js-composer .vc_row.vc_row-o-equal-height {
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-flex-wrap: wrap;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
}
.wpb-js-composer .vc_row.vc_row-o-equal-height > .vc_column_container {
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
}
.wpb-js-composer .vc_row.vc_row-o-equal-height > .vc_column_container > .vc_column-inner {
    -webkit-box-flex: 1;
    -webkit-flex: 1;
    -ms-flex: 1;
    flex: 1;
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -webkit-flex-direction: column;
    -ms-flex-direction: column;
    flex-direction: column;
}

/* Row: content placement (works with equal-height flex) */
.wpb-js-composer .vc_row.vc_row-o-content-middle.vc_row-o-equal-height > .vc_column_container > .vc_column-inner {
    -webkit-box-pack: center;
    -webkit-justify-content: center;
    -ms-flex-pack: center;
    justify-content: center;
}
.wpb-js-composer .vc_row.vc_row-o-content-bottom.vc_row-o-equal-height > .vc_column_container > .vc_column-inner {
    -webkit-box-pack: end;
    -webkit-justify-content: flex-end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

/* Text block: ensure paragraph spacing is preserved regardless of theme reset */
.wpb-js-composer .wpb_text_column p,
.wpb-js-composer .wpb_text_column .wpb_wrapper p {
    margin-top: 0;
    margin-bottom: 1em;
}
.wpb-js-composer .wpb_text_column p:last-child,
.wpb-js-composer .wpb_text_column .wpb_wrapper p:last-child {
    margin-bottom: 0;
}

/* ============================================================
   Facility single — default layout (v1.2.5)
   Replaces the old single-column hero+list layout with a
   gallery + two-column (content | contact card) design.
   ============================================================ */

/* Widen the default layout to use more screen estate */
.dh-fac-default-layout {
    max-width: 1100px;
    margin: 0 auto;
}

/* ── Facility name row ── */
.dh-fac-name-row {
    margin: 12px 0 8px;
}
.dh-fac-name-row h1 {
    font-size: 1.9rem;
    margin: 0;
    line-height: 1.25;
}
.dh-fac-verified {
    color: var(--dh-primary);
    font-size: 1.1rem;
    vertical-align: middle;
    margin-left: 6px;
}

/* ── Meta row: rating + type badges ── */
.dh-fac-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 14px;
    margin-bottom: 20px;
    font-size: 0.88rem;
    color: #555;
}
.dh-fac-rating {
    display: flex;
    align-items: center;
    gap: 4px;
}
.dh-fac-stars {
    color: #f5a623;
    letter-spacing: 1px;
}
.dh-fac-rating-score {
    font-weight: 700;
    color: var(--dh-text);
}
.dh-fac-rating-count {
    color: #888;
}
.dh-fac-type-badge {
    background: #eef2f7;
    border: 1px solid #c9d6e3;
    border-radius: 20px;
    padding: 3px 11px;
    font-size: 0.78rem;
    color: #444;
}

/* ── Gallery ── */
.dh-fac-gallery {
    margin-bottom: 28px;
    border-radius: var(--dh-radius);
    overflow: hidden;
    line-height: 0;
}

/* 1 image: full width */
.dh-fac-gallery--1 .dh-fac-gallery-main img {
    width: 100%;
    height: 460px;
    object-fit: cover;
    display: block;
}

/* 2–5 images: left main + right side grid */
.dh-fac-gallery--2,
.dh-fac-gallery--3,
.dh-fac-gallery--4,
.dh-fac-gallery--5 {
    display: flex;
    gap: 4px;
    height: 460px;
}
.dh-fac-gallery--2 .dh-fac-gallery-main,
.dh-fac-gallery--3 .dh-fac-gallery-main,
.dh-fac-gallery--4 .dh-fac-gallery-main,
.dh-fac-gallery--5 .dh-fac-gallery-main {
    flex: 0 0 60%;
    overflow: hidden;
    border-radius: var(--dh-radius);
}
.dh-fac-gallery--2 .dh-fac-gallery-main img,
.dh-fac-gallery--3 .dh-fac-gallery-main img,
.dh-fac-gallery--4 .dh-fac-gallery-main img,
.dh-fac-gallery--5 .dh-fac-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Side grid (right column) */
.dh-fac-gallery-side {
    flex: 1;
    display: grid;
    gap: 4px;
    overflow: hidden;
}
/* 1 side image: fills the right column */
.dh-fac-gallery-side--1 {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
}
/* 2 side images: stacked vertically */
.dh-fac-gallery-side--2 {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr 1fr;
}
/* 3 side images: three equal rows in a single column */
.dh-fac-gallery-side--3 {
    grid-template-columns: 1fr;
    grid-template-rows: repeat(3, 1fr);
}
/* 4 side images: 2×2 grid */
.dh-fac-gallery-side--4 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}
.dh-fac-gallery-side-img {
    overflow: hidden;
    cursor: pointer;
    border-radius: var(--dh-radius);
}
.dh-fac-gallery-side-img.dh-active {
    box-shadow: inset 0 0 0 3px #fff;
}
.dh-fac-gallery-side-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.25s ease;
}
.dh-fac-gallery-side-img:hover img,
.dh-fac-gallery-side-img:focus img {
    transform: scale(1.04);
}

/* Responsive: stack vertically on narrow screens */
@media (max-width: 640px) {
    .dh-fac-gallery--2,
    .dh-fac-gallery--3,
    .dh-fac-gallery--4,
    .dh-fac-gallery--5 {
        flex-direction: column;
        height: auto;
    }
    .dh-fac-gallery--2 .dh-fac-gallery-main,
    .dh-fac-gallery--3 .dh-fac-gallery-main,
    .dh-fac-gallery--4 .dh-fac-gallery-main,
    .dh-fac-gallery--5 .dh-fac-gallery-main {
        flex: none;
    }
    .dh-fac-gallery--2 .dh-fac-gallery-main img,
    .dh-fac-gallery--3 .dh-fac-gallery-main img,
    .dh-fac-gallery--4 .dh-fac-gallery-main img,
    .dh-fac-gallery--5 .dh-fac-gallery-main img {
        height: 260px;
    }
    .dh-fac-gallery--1 .dh-fac-gallery-main img {
        height: 260px;
    }
    /* Thumbnail strip: single scrollable row instead of a fixed-height grid */
    .dh-fac-gallery-side {
        display: flex;
        flex-direction: row;
        overflow-x: auto;
        overflow-y: hidden;
        height: 80px;
        gap: 4px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
    }
    .dh-fac-gallery-side::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }
    .dh-fac-gallery-side-img {
        flex: 0 0 80px;
        width: 80px;
        min-width: 80px;
        height: 80px;
    }
}

/* ── Two-column body ── */
.dh-fac-body-cols {
    display: flex;
    gap: 32px;
    margin-bottom: 32px;
}
.dh-fac-main-col {
    flex: 1 1 0%;
    min-width: 0;
}
.dh-fac-sidebar {
    flex: 0 0 300px;
    width: 300px;
    /* align-self: flex-start + position: sticky together: sidebar shrinks to card height
       (no white space below) while the card sticks to viewport top during scroll.
       The exact 'top' offset is overridden per-page via inline style from the
       'sidebar_sticky_top' admin setting (Drughelp → Settings). */
    align-self: flex-start;
    position: sticky;
    top: 50px;
}

/* ── About section ── */
.dh-fac-about {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--dh-border);
}
.dh-fac-about h2 {
    font-size: 1.25rem;
    margin: 0 0 12px;
}
.dh-fac-about-body {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #444;
}

/* ── Highlights from the Center ── */
.dh-fac-highlights {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--dh-border);
}
.dh-fac-highlights h3 {
    font-size: 0.88rem;
    font-weight: 600;
    margin: 0 0 12px;
    color: #555;
    display: flex;
    align-items: center;
    gap: 6px;
}
.dh-fac-highlights-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
}
.dh-fac-highlight-item {
    font-size: 0.88rem;
    color: #333;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.dh-fac-highlight-item::before {
    content: '\2713';
    color: var(--dh-primary);
    font-weight: 700;
    font-size: 0.9em;
}

/* ── AT A GLANCE label + title ── */
.dh-at-a-glance {
    margin-bottom: 24px;
}
.dh-ata-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #999;
    margin: 0 0 3px;
    font-weight: 600;
}
.dh-ata-title {
    font-size: 1.25rem;
    margin: 0 0 14px;
    color: var(--dh-text);
}

/* ── Overview grid — 2-column hairline ── */
/* Overrides the older .dh-center-overview auto-fill grid */
.dh-overview-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: var(--dh-border);
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    overflow: hidden;
}
.dh-overview-grid .dh-overview-item {
    border: none;
    border-radius: 0;
    margin: 0;
    background: #fff;
}

/* ── Sidebar contact card ── */
.dh-contact-card {
    background: #fff;
    border: 1px solid var(--dh-border);
    border-radius: var(--dh-radius);
    padding: 22px 18px;
    box-shadow: 0 2px 10px rgba(0,0,0,.07);
}
.dh-contact-card-logo {
    display: block;
    width: 100%;
    max-height: 140px;
    object-fit: cover;
    border-radius: calc(var(--dh-radius) - 2px);
    margin: 0 0 14px;
}
.dh-contact-card-name {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 6px;
    line-height: 1.35;
    color: var(--dh-text);
}
.dh-contact-card-rating {
    color: #555;
    font-size: 0.85rem;
    margin-bottom: 12px;
}
.dh-contact-card-featured {
    margin-bottom: 10px;
}
.dh-contact-card-phone-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #0066F5;
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.9rem;
    min-height: 44px;
    box-sizing: border-box;
    width: 100%;
    margin-bottom: 10px;
    cursor: pointer;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    transition: background 0.2s, color 0.2s;
}
.dh-contact-card-phone-btn:hover {
    background: #000;
    color: #fff;
    text-decoration: none;
}
.dh-contact-card-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--dh-bg);
    border: 1px solid var(--dh-border);
    color: var(--dh-text);
    text-decoration: none;
    padding: 11px 16px;
    border-radius: var(--dh-radius);
    font-size: 0.88rem;
    margin-bottom: 8px;
    transition: background 0.2s;
}
.dh-contact-card-link:hover {
    background: #e8ecf0;
    color: var(--dh-text);
    text-decoration: none;
}
.dh-contact-card-arrow {
    font-size: 1.2em;
    opacity: .7;
}
.dh-contact-card-address {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--dh-border);
    font-size: 0.78rem;
    color: #777;
    line-height: 1.55;
}
.dh-contact-card-address a {
    color: var(--dh-primary);
    text-decoration: none;
}
.dh-contact-card-address a:hover {
    text-decoration: underline;
}

/* ── Responsive ── */
@media (max-width: 860px) {
    .dh-fac-sidebar {
        flex: 0 0 240px;
        width: 240px;
    }
}
@media (max-width: 680px) {
    .dh-fac-body-cols {
        flex-direction: column;
    }
    .dh-fac-sidebar {
        flex: none;
        width: 100%;
        position: static;
    }
    .dh-overview-grid {
        grid-template-columns: 1fr;
    }
    .dh-fac-name-row h1 {
        font-size: 1.5rem;
    }
}

/* ── Contact card: treatment type sub-line ── */
.dh-contact-card-types {
    font-size: 0.8rem;
    color: #777;
    margin-bottom: 14px;
}

/* ── CALL NOW button ── */
.dh-call-now-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #0066F5;
    color: #fff !important;
    text-decoration: none !important;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.9rem;
    min-height: 44px;
    box-sizing: border-box;
    cursor: pointer;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.dh-call-now-btn:hover {
    background: #000;
    color: #fff !important;
}
.dh-call-now-icon {
    font-size: 1.1em;
}
.dh-state-call-number {
    font-size: 0.95em;
    opacity: 0.9;
}
.dh-state-call-bar {
    margin: 16px 0;
}

/* ── CONTACT US button (sidebar + overview) ── */
.dh-contact-us-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #BDEBEF;
    color: #000 !important;
    text-decoration: none !important;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.9rem;
    min-height: 44px;
    box-sizing: border-box;
    cursor: pointer;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-family: inherit;
    width: 100%;
    margin-top: 8px;
}
.dh-contact-us-btn:hover {
    background: #0066F5;
    color: #fff !important;
}
.dh-contact-us-icon {
    font-size: 1.1em;
}

/* Row holding CALL NOW + CONTACT US side by side in the overview */
.dh-overview-btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.dh-overview-btn-row .dh-call-now-btn,
.dh-overview-btn-row .dh-contact-us-btn {
    width: auto;
    margin-top: 0;
}

/* ── Global Message Center Lightbox ── */
.dh-msg-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.dh-msg-lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.6);
}
.dh-msg-lightbox-inner {
    position: relative;
    background: #fff;
    border-radius: 8px;
    padding: 32px 28px 24px;
    max-width: 540px;
    width: 92%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 40px rgba(0,0,0,0.2);
}
.dh-msg-lightbox-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: #555;
    line-height: 1;
    padding: 0;
}
.dh-msg-lightbox-close:hover {
    color: #000;
}
.dh-msg-lightbox-inner h2 {
    margin: 0 0 4px;
    font-size: 1.4rem;
}
.dh-msg-facility-name {
    color: #777;
    font-size: 0.9rem;
    margin-bottom: 18px;
}
.dh-msg-field {
    margin-bottom: 14px;
}
.dh-msg-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    font-size: 0.88rem;
}
.dh-msg-field input[type="text"],
.dh-msg-field input[type="email"],
.dh-msg-field input[type="tel"],
.dh-msg-field textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.95rem;
    box-sizing: border-box;
}
.dh-msg-field textarea {
    resize: vertical;
}
.dh-msg-radio-group,
.dh-msg-checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
}
.dh-msg-radio,
.dh-msg-checkbox {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 400;
    font-size: 0.9rem;
    cursor: pointer;
}
.dh-msg-robot-field {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #eee;
}
.dh-msg-robot-label {
    font-size: 0.95rem !important;
    font-weight: 600 !important;
}
.dh-msg-submit-wrap {
    margin-top: 14px;
}
.dh-msg-submit {
    background: var(--dh-primary, #4a90d9);
    color: #fff;
    border: none;
    padding: 11px 28px;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
}
.dh-msg-submit:hover {
    background: #2c6cb0;
}
.dh-msg-response {
    margin-top: 12px;
    font-size: 0.9rem;
}
.dh-msg-response.dh-msg-success {
    color: #2e7d32;
}
.dh-msg-response.dh-msg-error {
    color: #c0392b;
}

/* ============================================================================
   v2.0.4 — Image-based accreditation badges, amenity icons, treatment page
   ============================================================================ */

/* Accreditation badge with image */
.dh-accred-badge--img {
    background: transparent;
    border: none;
    padding: 0;
}
.dh-accred-badge--img img {
    height: 28px;
    width: auto;
    max-width: 80px;
    object-fit: contain;
    display: block;
}

/* Accreditation images on facility page (overview grid) */
.dh-accred-images {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.dh-accred-img-wrap img {
    height: 36px;
    width: auto;
    max-width: 100px;
    object-fit: contain;
}

/* Amenity image icon */
.dh-amenity-icon--img {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.dh-amenity-icon--img img {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

/* Amenity images on facility page (overview grid) */
.dh-amenity-images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}
.dh-amenity-img-wrap {
    display: inline-flex;
    align-items: center;
}
.dh-amenity-img-wrap img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* Treatment page: icon + H1 side-by-side row */
.dh-treatment-heading {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 0 0 16px;
}
.dh-treatment-heading h1 {
    margin: 0;
}
.dh-treatment-icon {
    flex-shrink: 0;
}
.dh-treatment-icon img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    display: block;
}
/* Treatment page: description below the heading row */
.dh-treatment-description {
    font-size: 0.97rem;
    line-height: 1.65;
    color: #555;
}

/* Treatment page: state filter bar */
.dh-treatment-state-filter {
    margin: 20px 0 16px;
}
.dh-filter-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.dh-filter-bar label {
    font-weight: 600;
    font-size: 0.9rem;
}
.dh-filter-bar select {
    padding: 6px 10px;
    border: 1px solid var(--dh-border, #ddd);
    border-radius: var(--dh-radius, 4px);
    font-size: 0.9rem;
}
.dh-filter-clear {
    font-size: 0.85rem;
}

/* ============================================================
   Author Bio Card
   ============================================================ */
.dh-author-bio {
    margin: 48px 0 32px;
    padding: 0 16px;
}
.dh-author-bio-inner {
    display: flex;
    align-items: flex-start;
    gap: 28px;
    background: linear-gradient(135deg, #f8f9ff 0%, #fff 100%);
    border: 1px solid #e1e4f0;
    border-radius: 16px;
    padding: 32px 36px;
    box-shadow: 0 4px 24px rgba(74, 144, 217, 0.08);
    position: relative;
    overflow: hidden;
    max-width: 860px;
    margin: 0 auto;
}
.dh-author-bio-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: linear-gradient(180deg, #4a90d9, #2c5aa0);
    border-radius: 16px 0 0 16px;
}
.dh-author-bio-avatar {
    flex-shrink: 0;
}
.dh-author-bio-photo {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #fff;
    box-shadow: 0 4px 16px rgba(74, 144, 217, 0.2);
    display: block;
}
.dh-author-bio-content {
    flex: 1;
    min-width: 0;
}
.dh-author-bio-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #4a90d9;
    margin: 0 0 4px;
}
.dh-author-bio-name {
    font-size: 22px;
    font-weight: 700;
    color: #1a2540;
    margin: 0 0 4px;
    line-height: 1.2;
}
.dh-author-bio-title {
    font-size: 14px;
    color: #6b7280;
    font-style: italic;
    margin: 0 0 14px;
}
.dh-author-bio-text {
    font-size: 15px;
    line-height: 1.7;
    color: #374151;
    margin-bottom: 18px;
}
.dh-author-bio-text p:last-child {
    margin-bottom: 0;
}
.dh-author-bio-social {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}
.dh-author-bio-social-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 15px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    background: #f0f4ff;
    color: #2c5aa0;
    border: 1.5px solid #c7d5f0;
}
.dh-author-bio-social-link:hover {
    background: #4a90d9;
    color: #fff;
    border-color: #4a90d9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 144, 217, 0.3);
    text-decoration: none;
}
.dh-author-bio-social-link i {
    font-size: 14px;
}
.dh-author-bio-social-facebook { color: #1877f2; border-color: #c5d8fd; background: #f0f5ff; }
.dh-author-bio-social-facebook:hover { background: #1877f2; color: #fff; border-color: #1877f2; }
.dh-author-bio-social-twitter { color: #000; border-color: #d0d0d0; background: #f7f7f7; }
.dh-author-bio-social-twitter:hover { background: #000; color: #fff; border-color: #000; }
.dh-author-bio-social-linkedin { color: #0a66c2; border-color: #c2d9f5; background: #f0f6ff; }
.dh-author-bio-social-linkedin:hover { background: #0a66c2; color: #fff; border-color: #0a66c2; }
.dh-author-bio-social-instagram { color: #e1306c; border-color: #f5c0d4; background: #fff0f5; }
.dh-author-bio-social-instagram:hover { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); color: #fff; border-color: #e1306c; }
.dh-author-bio-social-youtube { color: #ff0000; border-color: #ffc0c0; background: #fff5f5; }
.dh-author-bio-social-youtube:hover { background: #ff0000; color: #fff; border-color: #ff0000; }
@media (max-width: 640px) {
    .dh-author-bio-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 28px 20px;
    }
    .dh-author-bio-social {
        justify-content: center;
    }
    .dh-author-bio-social-link span {
        display: none;
    }
    .dh-author-bio-social-link {
        width: 40px;
        height: 40px;
        justify-content: center;
        padding: 0;
    }
    .dh-author-bio-inner::before {
        width: 100%;
        height: 6px;
        border-radius: 16px 16px 0 0;
    }
}
