/* ==========================================================================
   WORK MAP MODULE STYLES
   ========================================================================== */
#work-map .state {
    fill: #b1b1b1;
    stroke: #ffffff;
    stroke-width: 0.5;
    transition: all 0.3s ease;
    cursor: default;
}

#work-map .state.has-locations { fill: #be9141; cursor: pointer; }
#work-map .state.has-locations:hover { fill: #c49a4e; }
#work-map .state:hover { fill: #d1d5db; }
#work-map .state.highlighted { fill: #be9141; stroke: #ffffff; stroke-width: 1; }
#work-map .state.highlighted:hover { fill: #c49a4e; }

#state-logos-layer { pointer-events: none; }
.state-logo-group {
    pointer-events: all;
    cursor: pointer;
    opacity: 0;
    animation: logoFadeIn 0.35s ease forwards;
    transition: transform 0.2s ease;
}

.state-logo-group:hover {
    transform: translateY(-4px);
}

.state-logo-group:hover circle:first-child {
    stroke: #1a365d;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.25));
}

.state-logo-group circle:first-child {
    transition: all 0.2s ease;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.15));
}

@keyframes logoFadeIn {
    from { opacity: 0; transform: translateY(8px) scale(0.8); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

#pins-layer { pointer-events: all; }
.pin-group { cursor: pointer; }

.pin-pill-bg {
    fill: #ffffff;
    stroke: #e2e8f0;
    stroke-width: 1.5;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.08));
    transition: all 0.2s ease;
    cursor: pointer;
}

.pin-group:hover .pin-pill-bg {
    stroke: #be9141;
    stroke-width: 2;
    filter: drop-shadow(0 4px 12px rgba(190, 145, 65, 0.3));
    transform: translateY(-1px);
}

.pin-pill-text {
    font-size: 10px;
    fill: #00205b;
    text-anchor: middle;
    pointer-events: none;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
}

/* Location and Video Popups for Work Map */
#locationPopup, #videoPopup {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 20px;
    box-sizing: border-box;
}

#locationPopup.active, #videoPopup.active { display: flex; }

#locationPopup .popup, #videoPopup .popup {
    background: #fff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 680px;
    width: 100%;
    animation: popupIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    position: relative;
    border: 1px solid #e2e8f0;
}

#videoPopup .popup-large { max-width: 900px; }

@keyframes popupIn {
    from { opacity: 0; transform: scale(0.95) translateY(16px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.popup-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #f8fafc;
}

.popup-image-container.has-video { cursor: pointer; }

/* Dynamic play button icon overlay styling */
.play-overlay-btn {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 72px; height: 72px;
    background: #be9141;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    box-shadow: 0 10px 25px rgba(190, 145, 65, 0.35);
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.popup-image-container:hover .play-overlay-btn {
    transform: translate(-50%, -50%) scale(1.1);
    background: #c49a4e;
    box-shadow: 0 10px 25px rgba(190, 145, 65, 0.45);
}

.play-overlay-btn::before {
    content: '';
    display: block;
    width: 0; height: 0;
    border-left: 20px solid #fff;
    border-top: 12px solid transparent;
    border-bottom: 12px solid transparent;
    margin-left: 6px;
}

.popup-image-container .popup-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.popup-image-container:hover .popup-image {
    transform: scale(1.03);
}

.popup-floating-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 50;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #e2e8f0;
    color: #1e293b;
    font-size: 20px;
    font-weight: 300;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
}

.popup-floating-close:hover {
    background: #fff;
    color: #be9141;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Widescreen popup body footer layout */
.popup-footer-bar {
    padding: 24px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #fff;
    border-top: 1px solid #f1f5f9;
}

.popup-brand-logo-img {
    max-height: 44px;
    width: auto;
    object-fit: contain;
    display: block;
}

.popup-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #00205b;
    color: #fff !important;
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 500;
    padding: 12px 28px;
    border-radius: 9999px;
    text-decoration: none !important;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px rgba(0, 32, 91, 0.2);
}

.popup-cta-btn:hover {
    background: #be9141;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(190, 145, 65, 0.3);
}

.popup-cta-btn svg {
    transition: transform 0.2s ease;
}

.popup-cta-btn:hover svg {
    transform: translateX(4px);
}

.popup-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.popup-body { padding: 24px; }

.popup-location-name {
    font-size: 22px;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 12px;
    font-family: system-ui, -apple-system, sans-serif;
}

.popup-description {
    font-size: 15px;
    line-height: 1.7;
    color: #4a5568;
    font-family: system-ui, -apple-system, sans-serif;
}
.popup-header {
    position: relative;
    background: #111827;
    color: #fff;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    font-family: 'Outfit', sans-serif;
    z-index: 10;
}

.popup-title {
    font-size: 16px;
    font-weight: 500;
    color: #fff;
    letter-spacing: 0.02em;
    margin: 0;
}

.popup-close {
    background: rgba(255,255,255,0.08);
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.popup-close:hover {
    background: #be9141;
    color: #fff;
    transform: scale(1.05);
}

.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    background: #000;
    border-radius: 0 0 16px 16px;
    overflow: hidden;
}

.video-container iframe,
.video-container video {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}

.video-placeholder {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1a365d 0%, #2d3748 100%);
    color: #fff;
}

.play-button-large {
    width: 80px; height: 80px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.3);
}

.play-button-large:hover {
    transform: scale(1.1);
    background: rgba(255,255,255,0.3);
    border-color: rgba(255,255,255,0.5);
}

.play-button-large::after {
    content: '';
    width: 0; height: 0;
    border-left: 28px solid #fff;
    border-top: 16px solid transparent;
    border-bottom: 16px solid transparent;
    margin-left: 6px;
}

.pin-tooltip {
    position: fixed;
    background: #1a202c;
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    pointer-events: none;
    z-index: 10000;
    opacity: 0;
    transform: translateY(4px);
    transition: all 0.2s ease;
    white-space: nowrap;
    font-family: system-ui, -apple-system, sans-serif;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.pin-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

.pin-tooltip::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0; height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #1a202c;
}

@media (max-width: 768px) {
    #work-map .popup,
    .ml-modal-overlay .popup { max-width: calc(100% - 40px); }
    #work-map .popup-large { max-width: calc(100% - 40px); }
    .popup-image-container { height: 200px; }
    .popup-location-name { font-size: 20px; }
    .popup-description { font-size: 14px; }
    
    .play-button-large {
        width: 60px; height: 60px;
    }
    .play-button-large::after {
        border-left-width: 20px;
        border-top-width: 12px;
        border-bottom-width: 12px;
    }
}

/* State logo pill styling */
.state-logo-group {
    animation: logoPopIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    opacity: 0;
    transform-origin: center;
}

@keyframes logoPopIn {
    from { opacity: 0; transform: scale(0.5); }
    to { opacity: 1; transform: scale(1); }
}

.state-logo-group:hover .pill-bg {
    stroke: #be9141;
    stroke-width: 2;
    filter: drop-shadow(0 2px 8px rgba(190, 145, 65, 0.3));
}

@keyframes pinPopIn {
    from { opacity: 0; transform: scale(0); }
    to { opacity: 1; transform: scale(1); }
}

.pin-pill-text {
    fill: #00205b;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 10px;
    pointer-events: none;
    user-select: none;
}

/* State hover effects */
#work-map .state {
    transition: fill 0.2s ease;
    fill: #e5e7eb;
}

#work-map .state:hover {
    fill: #d1d5db;
}

#work-map .state.has-locations {
    fill: #be9141;
}

#work-map .state.has-locations:hover {
    fill: #be9141;
}

#work-map .state.highlighted {
    fill: #be9141;
}


/* ==========================================================================
   MAP LOCATIONS MODULE STYLES
   ========================================================================== */
.site-map-locations {
    font-family: 'Outfit', sans-serif;
}
.site-map-locations .highlight {
    color: #be9141;
    background: linear-gradient(to right, #be9141 0%, #d4af37 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.site-map-locations .text-gold {
    color: #d4af37;
}

#usa-map {
    width: 100%;
    height: 100%;
    max-width: 1000px;
    display: block;
}
#map-locations .state {
    fill: #e2e8f0;
    stroke: #ffffff;
    stroke-width: 1;
    transition: fill 0.3s ease, stroke 0.3s ease, filter 0.3s ease;
}
#map-locations .state.has-location {
    cursor: pointer;
}
#map-locations .state.has-location:hover,
#map-locations .state.has-location.hover-active,
#map-locations .state.highlighted {
    fill: #be9141;
    stroke: #ffffff;
    stroke-width: 1.5;
    filter: drop-shadow(0 4px 6px rgba(190, 145, 65, 0.3));
}

.state-label-text {
    font-size: 7px;
    font-weight: 500;
    fill: #64748b;
    pointer-events: none;
    user-select: none;
    font-family: 'Outfit', sans-serif;
    transition: fill 0.3s ease, font-weight 0.3s ease;
}
.state-label-text.active {
    fill: #ffffff;
    font-weight: 700;
}

/* Grey by default — every state with a video gets a pin on load. Gold is
   reserved for whichever state is currently selected (see .is-active). */
.map-marker {
    cursor: pointer;
    filter: drop-shadow(0 2px 6px rgba(15, 23, 42, 0.25));
}
.map-marker .pin-body,
.map-marker .pin-dot {
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), fill 0.3s ease;
    transform-origin: 0px 0px;
}
.map-marker:hover .pin-body,
.map-marker:hover .pin-dot,
.map-marker.hover-active .pin-body,
.map-marker.hover-active .pin-dot {
    transform: scale(1.15);
}
.map-marker .pin-body {
    fill: #94a3b8;
    stroke: #ffffff;
    stroke-width: 1.5;
}
.map-marker .pin-dot {
    fill: #ffffff;
}
.map-marker.is-active,
.map-marker:hover,
.map-marker.hover-active {
    filter: drop-shadow(0 4px 12px rgba(190, 145, 65, 0.45));
}
.map-marker.is-active .pin-body,
.map-marker:hover .pin-body,
.map-marker.hover-active .pin-body {
    fill: #be9141;
}

.location-tab {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}
.location-tab .loc-city { 
    color: #111111;
    font-weight: 500;
}
.location-tab .loc-zip { 
    color: #64748b; 
}
.location-tab:hover {
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}
.location-tab.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #be9141 0%, #d4af37 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(190, 145, 65, 0.3);
}
.location-tab.is-active .loc-city {
    color: #ffffff;
    font-weight: 600;
}
.location-tab.is-active .loc-zip {
    color: rgba(255, 255, 255, 0.9);
}

/* Homepage featured Case Studies only. Portfolio keeps its existing grid. */
.homepage-case-study-map .homepage-case-study-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    width: 100%;
    max-width: 1080px;
    margin: 32px auto 0;
}

.homepage-case-study-map .case-study-map-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 112px;
    padding: 20px 24px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.06);
    color: #111111;
    cursor: pointer;
    text-align: center;
}

.homepage-case-study-map .case-study-map-button .loc-city {
    font-size: clamp(1rem, 1.4vw, 1.125rem);
    font-weight: 500;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.homepage-case-study-map .case-study-map-button:hover {
    border-color: #be9141;
    box-shadow: 0 10px 20px -5px rgba(190, 145, 65, 0.24);
}

.homepage-case-study-map .case-study-map-button.is-active {
    border-color: #be9141;
    background: linear-gradient(135deg, #be9141 0%, #d4af37 100%);
    transform: none;
    box-shadow: 0 10px 20px -5px rgba(190, 145, 65, 0.32);
}

.homepage-case-study-map .case-study-map-button:focus-visible {
    outline: 3px solid #be9141;
    outline-offset: 3px;
}

.homepage-case-study-map .case-study-map-button:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

@media (min-width: 640px) {
    .homepage-case-study-map .homepage-case-study-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        margin-top: 48px;
    }
}

@media (min-width: 1024px) {
    .homepage-case-study-map .homepage-case-study-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 24px;
    }
}

.ml-modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    padding: 20px;
    box-sizing: border-box;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.ml-modal-overlay.active {
    display: flex;
    opacity: 1;
}
.ml-modal-content {
    transform: scale(0.95) translateY(10px);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.ml-modal-overlay.active .ml-modal-content {
    transform: scale(1) translateY(0);
}
.ml-modal-close:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.ml-video-player-container video,
.ml-video-player-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* ------------------------------------------------------------------
   Homepage "Featured States" map (front page only - .homepage-state-map).
   Completed states gold, every other state dark with no hover; hover
   card, tour pop-up, and project cards in place of the map on phones.
   ------------------------------------------------------------------ */
#map-locations.homepage-state-map .state {
    fill: #1b3358;
    stroke: #2c4a76;
    stroke-width: 0.8;
    pointer-events: none;
    filter: none;
}
#map-locations.homepage-state-map .state.is-completed {
    fill: #be9141;
    stroke: #ffffff;
    stroke-width: 1.2;
    pointer-events: auto;
    cursor: pointer;
    outline: none;
}
#map-locations.homepage-state-map .state.is-completed:hover,
#map-locations.homepage-state-map .state.is-completed:focus {
    fill: #c49a4e;
    filter: drop-shadow(0 4px 6px rgba(190, 145, 65, 0.35));
}
.homepage-state-map .hsm-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 28px;
    margin: 32px 0 0;
    padding: 0;
    list-style: none;
    font-size: 15px;
    color: #333333;
}
.homepage-state-map .hsm-legend li { display: inline-flex; align-items: center; gap: 10px; }
.homepage-state-map .hsm-swatch { width: 16px; height: 16px; border-radius: 3px; display: inline-block; }
.homepage-state-map .hsm-swatch--completed { background: #be9141; }
.homepage-state-map .hsm-swatch--future { background: #1b3358; }
.homepage-state-map .hsm-tooltip {
    position: absolute;
    z-index: 5;
    transform: translate(-50%, calc(-100% - 10px));
    min-width: 180px;
    max-width: 240px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
    text-align: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.homepage-state-map .hsm-tooltip.is-visible { opacity: 1; }
.homepage-state-map .hsm-tooltip.is-below { transform: translate(-50%, 10px); }
.homepage-state-map .hsm-tooltip-logo { display: block; max-width: 140px; max-height: 48px; margin: 0 auto 8px; object-fit: contain; }
.homepage-state-map .hsm-tooltip-name { margin: 0 0 10px; font-weight: 600; color: #111111; line-height: 1.25; }
.homepage-state-map .hsm-watch {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 18px;
    border-radius: 999px;
    background: #00205b;
    color: #ffffff;
    font-weight: 500;
    font-size: 14px;
    transition: background 0.3s ease;
}
.homepage-state-map .hsm-watch:hover,
.homepage-state-map .hsm-watch:focus-visible { background: #be9141; }
.homepage-state-map .hsm-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 20px 0 0;
    color: #555555;
    font-size: 15px;
}
.homepage-state-map .hsm-cards { display: none; }

/* Phones: cards instead of the map (the map, legend and hint hide below 768px). */
@media (max-width: 767px) {
    .homepage-state-map .map-card-wrapper,
    .homepage-state-map .hsm-legend,
    .homepage-state-map .hsm-hint { display: none; }
    .homepage-state-map .hsm-cards { display: grid; gap: 16px; margin-top: 28px; }
    .homepage-state-map .hsm-card {
        padding: 20px;
        border: 1px solid #e2e8f0;
        border-radius: 16px;
        background: #f8fafc;
        text-align: center;
    }
    .homepage-state-map .hsm-card-logo { display: block; max-width: 160px; max-height: 56px; margin: 0 auto 12px; object-fit: contain; }
    .homepage-state-map .hsm-card-state { margin: 0; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: #be9141; font-weight: 600; }
    .homepage-state-map .hsm-card-name { margin: 4px 0 0; font-size: 20px; font-weight: 600; color: #111111; }
    .homepage-state-map .hsm-card-city { margin: 2px 0 14px; color: #555555; }
}

/* Tour pop-up */
.hsm-popup {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.7);
    opacity: 0;
    transition: opacity 0.25s ease;
}
.hsm-popup[hidden] { display: none; }
.hsm-popup.is-open { opacity: 1; }
body.hsm-popup-open { overflow: hidden; }
.hsm-popup-card {
    position: relative;
    width: 100%;
    max-width: 760px;
    padding: 28px 28px 24px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
}
.hsm-popup-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #1e293b;
    font-size: 26px;
    line-height: 1;
    transition: background 0.2s ease, color 0.2s ease;
}
.hsm-popup-close:hover { background: #be9141; color: #ffffff; }
.hsm-popup-label { margin: 0; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: #be9141; font-weight: 600; }
.hsm-popup-name { margin: 4px 40px 0 0; font-size: 26px; font-weight: 600; color: #111111; line-height: 1.2; }
.hsm-popup-city { margin: 2px 0 0; color: #555555; }
.hsm-popup-media {
    position: relative;
    margin-top: 18px;
    aspect-ratio: 16 / 9;
    border-radius: 16px;
    overflow: hidden;
    background: #0f172a;
}
.hsm-popup-thumb { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hsm-popup-play {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 72px;
    height: 72px;
    margin: -36px 0 0 -36px;
    border-radius: 50%;
    background: #be9141;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}
.hsm-popup-play::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 54%;
    transform: translate(-50%, -50%);
    border-style: solid;
    border-width: 13px 0 13px 22px;
    border-color: transparent transparent transparent #ffffff;
}
.hsm-popup-frame { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; border: 0; background: transparent; }
.hsm-popup-title { margin: 14px 0 0; font-weight: 600; color: #111111; }
@media (max-width: 767px) {
    .hsm-popup-card { padding: 22px 16px 18px; }
    .hsm-popup-name { font-size: 21px; }
}

/* Client 10/6: less empty space above and below the featured-states map, so
   "Click any gold state to explore our work" shows without scrolling. The map
   box now matches the map's own shape (SVG viewBox 593 x 318) instead of a
   12:7 frame, and the gaps around it are tighter. */
#map-locations.homepage-state-map .hsm-legend { margin-top: 24px; }
#map-locations.homepage-state-map .map-card-wrapper { margin-top: 16px; padding: 16px 24px; }
#map-locations.homepage-state-map .map-container {
    aspect-ratio: 593 / 318;
    max-width: 900px;
    margin: 0 auto;
}
#map-locations.homepage-state-map .hsm-hint { margin-top: 14px; }
