/* ============================================
   GOLDSTEP CAPITAL LTD - Branch Map Section
   branch-map.css
   Used on: home.html (preview), branch.html (full)
   Depends on: base.css
   ============================================ */

/* ============================================
   MAP SECTION WRAPPER
   ============================================ */
.branch-map-section {
    padding: var(--section-padding);
    background: var(--off-white);
}

.branch-map-section .section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px;
}

.branch-map-section .section-header p {
    color: var(--gray);
    line-height: 1.7;
}

/* ============================================
   MAP CARD (the white panel containing the map)
   ============================================ */
.branch-map-card {
    background: var(--white);
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    max-width: 700px;
    margin: 0 auto;
    box-shadow: var(--shadow-md);
}

/* Wider on the dedicated branch page */
.branch-map-section--full .branch-map-card {
    max-width: 100%;
}

/* ============================================
   MAP WRAP (SVG container)
   ============================================ */
.branch-map-wrap {
    padding: 24px 24px 12px;
    background: var(--white);
}

.branch-map-wrap svg {
    width: 100%;
    height: auto;
    display: block;
}

/* ============================================
   MAP LEGEND
   ============================================ */
.branch-map-legend {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
    padding: 12px 20px;
    border-top: 1px solid #eee;
    background: var(--off-white);
    font-size: 0.7rem;
    color: var(--gray);
}

.branch-map-legend__swatch {
    display: inline-block;
    width: 11px;
    height: 11px;
    border-radius: 2px;
    margin-right: 5px;
    vertical-align: middle;
}

.branch-map-legend__pin {
    vertical-align: middle;
    margin-right: 4px;
}

/* ============================================
   MAP STATS BAR
   ============================================ */
.branch-map-stats {
    display: flex;
    justify-content: space-around;
    padding: 14px 20px;
    border-top: 1px solid #eee;
    background: var(--off-white);
}

.branch-map-stats__num {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--gold-primary);
    text-align: center;
    font-family: var(--font-heading);
}

.branch-map-stats__lbl {
    font-size: 0.63rem;
    color: var(--gray-light);
    text-transform: uppercase;
    text-align: center;
    letter-spacing: 0.5px;
}

/* ============================================
   TOOLTIP
   ============================================ */
.branch-map-tooltip {
    position: fixed;
    background: var(--white);
    border: 1px solid var(--dark-charcoal);
    border-left: 3px solid var(--gold-primary);
    border-radius: 6px;
    padding: 10px 14px;
    font-family: var(--font-primary);
    font-size: 0.78rem;
    color: var(--charcoal);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.12s ease;
    z-index: 999;
    max-width: 240px;
    line-height: 1.55;
    box-shadow: var(--shadow-md);
}

.branch-map-tooltip.show {
    opacity: 1;
}

.branch-map-tooltip__name {
    display: block;
    font-weight: 600;
    color: var(--black);
    font-size: 0.85rem;
    margin-bottom: 2px;
}

.branch-map-tooltip__county {
    color: var(--gray-light);
    font-size: 0.72rem;
    margin-bottom: 5px;
}

.branch-map-tooltip__detail {
    color: var(--gray);
    font-size: 0.72rem;
    line-height: 1.7;
}

/* ============================================
   HOME PAGE VARIANT — compact teaser
   Shows map only, no stats/legend, with a
   "View all branches" CTA below
   ============================================ */
.branch-map-section--home .branch-map-card {
    max-width: 640px;
}

.branch-map-teaser-cta {
    text-align: center;
    margin-top: 30px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .branch-map-wrap {
        padding: 16px 16px 8px;
    }

    .branch-map-stats {
        gap: 0;
    }

    .branch-map-stats__num {
        font-size: 1.2rem;
    }

    .branch-map-legend {
        gap: 14px;
        font-size: 0.68rem;
    }
}