/* ── Where to Buy — Dealers Page (Dark Theme) ───────────────────── */

.wtb-dp-wrap {
    font-family: inherit;
    color: #f0f0f0;
    margin: 0;
}

/* ── Map ─────────────────────────────────────────────────────────── */
.wtb-dp-map-wrap {
    width: 100%;
    margin-bottom: 24px;
    overflow: hidden;
}
#wtb-dealers-map {
    width: 100%;
    height: 380px;
}

/* ── Stats bar ───────────────────────────────────────────────────── */
.wtb-dp-stats {
    display: flex;
    gap: 4px;
    margin-bottom: 20px;
}
.wtb-dp-stat {
    background: #222;
    border: 1px solid #2e2e36;
    padding: 14px 22px;
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.wtb-dp-stat-num {
    font-size: 24px;
    font-weight: 600;
    color: #fff;
    letter-spacing: -1px;
    line-height: 1;
}
.wtb-dp-stat-lbl {
    font-size: 11px;
    color: #ccc;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 500;
}

/* ── Controls row ────────────────────────────────────────────────── */
.wtb-dp-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}
.wtb-dp-search-wrap {
    flex: 1;
    position: relative;
    min-width: 200px;
}
.wtb-dp-search-icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    font-size: 16px;
    pointer-events: none;
    line-height: 1;
}
#wtb-dp-search {
    width: 100%;
    background: #222 !important;
    border: 1px solid #2e2e36;
    color: #f0f0f0;
    font-size: 14px;
    padding: 10px 14px 10px 38px;
    outline: none;
    box-sizing: border-box;
    border-radius: 0;
    appearance: none;
    -webkit-appearance: none;
    transition: border-color .15s;
	margin-bottom: 0;
}
#wtb-dp-search:focus { border-color: #fff; }
#wtb-dp-search::placeholder { color: #555; }

.wtb-dp-country-wrap {
    position: relative;
    min-width: 180px;
}
#wtb-dp-country {
    width: 100%;
    background: #222;
    border: 1px solid #2e2e36;
    color: #f0f0f0;
    font-size: 14px;
    padding: 10px 32px 10px 14px;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    border-radius: 0;
    cursor: pointer;
    transition: border-color .15s;
    box-sizing: border-box;
	margin-bottom: 0;
}
#wtb-dp-country:focus { border-color: #fff; }
#wtb-dp-country option { background: #1e1e24; }
.wtb-dp-select-arrow {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    pointer-events: none;
    font-size: 12px;
}

/* ── Brand pills ─────────────────────────────────────────────────── */
.wtb-dp-pills {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}
.wtb-dp-pill {
    background: #222;
    border: 1px solid #2e2e36;
    padding: 5px 16px;
    font-size: 12px;
    font-weight: 500;
    color: #ccc;
    cursor: pointer;
    letter-spacing: 0.3px;
    transition: border-color .15s, color .15s, background .15s;
    border-radius: 0;
}
.wtb-dp-pill:hover { border-color: #fff; color: #fff; }
.wtb-dp-pill.is-active {
    background: rgba(255,255,255,0.08);
    border-color: #fff;
    color: #fff;
}

/* ── Table wrapper — scrolls both ways, header sticks ───────────── */
.wtb-dp-table-wrap {
    width: 100%;
    overflow: auto;
    border: 1px solid #2e2e36;
    max-height: 600px;
    position: relative;
}

/* ── Table ───────────────────────────────────────────────────────── */
.wtb-dp-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 700px;
    font-size: 13px;
}

/* Sticky header — each th individually so it works inside overflow:auto */
.wtb-dp-th {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #212121;
    color: #ccc;
    padding: 11px 16px;
    text-align: left;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    white-space: nowrap;
    border-bottom: 2px solid #3a3a4a;
    box-shadow: 0 2px 0 #1a1a22;
}
.wtb-dp-th-brand,
.wtb-dp-td-brand { text-align: center !important; min-width: 80px; }
.wtb-dp-th-dealer  { min-width: 180px; }
.wtb-dp-th-country { min-width: 100px; }
.wtb-dp-th-address { min-width: 200px; }
.wtb-dp-th-url     { min-width: 160px; }

/* ── Rows ────────────────────────────────────────────────────────── */
.wtb-dp-row {
    border-bottom: 1px solid #2e2e36;
    background: transparent;
    transition: background .1s;
    white-space: nowrap;          /* keeps each row on one line */
}
.wtb-dp-row:hover        { background: #222 !important; }
.wtb-dp-row.is-hidden    { display: none; }
.wtb-dp-row.is-highlighted { background: #252530 !important; }

.wtb-dp-td {
    padding: 12px 16px;
    vertical-align: middle;
    color: #ccc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 240px;
}
.wtb-dp-td-dealer  { font-weight: 500; color: #f0f0f0; max-width: 200px; }
.wtb-dp-td-address { max-width: 260px; }
.wtb-dp-td-url     { max-width: 200px; }
.wtb-dp-td-brand   { max-width: none; }
.wtb-dp-td-country { max-width: 140px; }

/* ── Links (light on dark) ───────────────────────────────────────── */
.wtb-dp-map-link {
    color: #6ea8d8;
    text-decoration: none;
    font-weight: 500;
}
.wtb-dp-map-link:hover,
.wtb-dp-map-link:focus,
.wtb-dp-map-link:active,
.wtb-dp-map-link:visited { color: #9dc4e8; text-decoration: underline; }

.wtb-dp-url {
    color: #8aabcc;
    text-decoration: none;
    font-size: 12px;
}
.wtb-dp-url:hover,
.wtb-dp-url:focus,
.wtb-dp-url:active,
.wtb-dp-url:visited { color: #aac4e0; text-decoration: underline; }

/* ── Check / dash ────────────────────────────────────────────────── */
.wtb-dp-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    background: rgba(110,231,160,0.1);
    color: #6ee7a0;
    font-size: 12px;
    font-weight: 700;
}
.wtb-dp-dash { color: #4a4a58; }

/* ── Country tag ─────────────────────────────────────────────────── */
.wtb-dp-country-tag {
    display: inline-block;
    background: #212121;
    border: 1px solid #2e2e36;
    padding: 2px 8px;
    font-size: 12px;
    color: #ccc;
    font-weight: 500;
    white-space: nowrap;
}

/* ── No results ──────────────────────────────────────────────────── */
.wtb-dp-no-results {
    text-align: center;
    color: #ccc;
    padding: 48px;
    font-size: 14px;
    border: 1px solid #2e2e36;
    border-top: none;
    background: #111;
}

/* ── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .wtb-dp-stats       { flex-wrap: wrap; }
    .wtb-dp-controls    { flex-direction: column; }
    .wtb-dp-country-wrap { min-width: 100%; }
}
