﻿/* =========================================================
   OFFICE LOCATOR
========================================================= */

.office-locator-section {
    position: relative;
    width: 100%;
    padding: 32px 0 65px;
    background: #f7f8fa;
}


.office-locator-container {
    width: min(1450px, calc(100% - 40px));
    margin: 0 auto;
}


/* =========================================================
   MAIN LAYOUT
========================================================= */

.office-locator-grid {
    display: grid;
    grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.8fr);
    gap: 22px;
    align-items: start;
}


/* =========================================================
   LEFT PANEL
========================================================= */

.office-locator-panel {
    position: relative;
    min-width: 0;
}


/* =========================================================
   SEARCH CARD
========================================================= */

.office-locator-search {
    padding: 22px;
    border: 1px solid #e2e6eb;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 7px 22px rgba(15, 27, 45, .045);
}


.office-locator-search-heading {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 20px;
}


.office-locator-search-icon {
    width: 46px;
    height: 46px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #f8eeee;
    color: #880000;
    font-size: 18px;
}


.office-locator-label {
    display: block;
    margin-bottom: 3px;
    color: #880000;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1.3px;
}


.office-locator-search-heading h2 {
    margin: 0;
    color: #17243a;
    font-size: 18px;
    font-weight: 700;
}


/* =========================================================
   SELECT
========================================================= */

.office-select-label {
    display: block;
    margin-bottom: 8px;
    color: #536071;
    font-size: 12px;
    line-height: 1.5;
}


.office-select-wrapper {
    position: relative;
}


.office-select-icon {
    position: absolute;
    z-index: 2;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #880000;
    font-size: 13px;
    pointer-events: none;
}


.office-select {
    min-height: 45px;
    padding-left: 40px;
    border: 1px solid #dce1e7;
    border-radius: 7px;
    color: #24344a;
    font-size: 13px;
    background-color: #ffffff;
    box-shadow: none !important;
}


    .office-select:focus {
        border-color: rgba(136, 0, 0, .45);
        box-shadow: 0 0 0 3px rgba(136, 0, 0, .07) !important;
    }


/* =========================================================
   OFFICE DETAILS
========================================================= */

.office-details-panel {
    min-height: 180px;
    margin-top: 15px;
    padding: 16px;
    overflow: hidden;
    border: 1px solid #e2e6eb;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 7px 22px rgba(15, 27, 45, .04);
}


/* Empty state */

.office-empty-state {
    min-height: 145px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: #84909d;
    text-align: center;
}


.office-empty-icon {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f5f6f8;
    color: #880000;
    font-size: 17px;
}


.office-empty-state p {
    max-width: 220px;
    margin: 0;
    font-size: 11px;
    line-height: 1.5;
}

/* =========================================================
   LEFT OFFICE DETAILS
========================================================= */

.office-item {
    color: #24344a;
}

    .office-item b {
        font-size: 1rem;
        color: #0d2d66;
    }

.office-item-img {
    margin-bottom: 18px;
    overflow: hidden;
    border-radius: 9px;
}


    .office-item-img img {
        width: 100%;
        height: auto;
        display: block;
        object-fit: cover;
    }


/* REGION */

.office-item h5 {
    margin: 0 0 8px !important;
    color: #880000;
    font-size: 10px !important;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}


/* OFFICE NAME */

.office-item .text-muted {
    margin-bottom: 12px !important;
    color: #17243a !important;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
}


/* ADDRESS */

.office-item > div:not(.office-item-img):not(.text-muted) {
    color: rgb(48 53 60);
    font-size: 0.9rem;
    line-height: 1.7;
}


/* DIRECTIONS WRAPPER */

.office-item > div:last-child {
    margin-top: 16px !important;
}


/* DIRECTIONS BUTTON */

.office-item .wn-rm {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    border: 1px solid #880000;
    border-radius: 6px;
    background: #ffffff;
    color: #880000;
    font-size: 10px;
    font-weight: 700;
    text-decoration: none;
    transition: background .2s ease, color .2s ease, transform .2s ease;
}


    .office-item .wn-rm::before {
        content: "\f3c5";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
    }


    .office-item .wn-rm:hover {
        background: #880000;
        color: #ffffff;
        transform: translateY(-1px);
        text-decoration: none;
    }

/* =========================================================
   TIP
========================================================= */

.office-map-tip {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 12px;
    padding: 11px 13px;
    border-radius: 7px;
    background: #eef3f8;
    color: #607080;
    font-size: 10px;
    line-height: 1.5;
}


    .office-map-tip i {
        margin-top: 2px;
        color: #0c315d;
    }


/* =========================================================
   MAP PANEL
========================================================= */

.office-map-panel {
    min-width: 0;
    padding: 18px;
    border: 1px solid #e2e6eb;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 7px 24px rgba(15, 27, 45, .05);
}


/* =========================================================
   MAP HEADER
========================================================= */

.office-map-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 15px;
    padding: 0 2px;
}


    .office-map-header > div:first-child > span {
        display: block;
        margin-bottom: 3px;
        color: #880000;
        font-size: 8px;
        font-weight: 700;
        letter-spacing: 1.3px;
    }


    .office-map-header h2 {
        margin: 0;
        color: #17243a;
        font-size: 18px;
        font-weight: 700;
    }


/* =========================================================
   OFFICE COUNT
========================================================= */

.office-map-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 11px;
    border-radius: 20px;
    background: #f5f6f8;
    color: #536071;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}


    .office-map-status i {
        color: #880000;
    }


/* =========================================================
   MAP
========================================================= */

.office-map-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    border: 1px solid #e0e4e9;
    border-radius: 10px;
    background: #eef1f4;
}


#map {
    width: 100%;
    height: clamp(480px, 60vh, 650px);
    min-height: 480px;
}

/* =========================================================
   MAP INFO WINDOW
========================================================= */

.map-office-card {
    width: 300px;
    max-width: 100%;
    overflow: hidden;
    background: #ffffff;
    color: #263548;
    min-height: 350px;
}


/* IMAGE */

.map-office-img {
    width: 100%;
    height: auto;
    overflow: hidden;
    border-radius: 5px;
}


    .map-office-img img {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: cover;
        object-position: center 42%;
    }


/* CONTENT */

.map-office-body {
    padding: 11px 2px 2px;
}


    .map-office-body h5 {
        margin: 0 0 7px;
        color: #17243a;
        font-size: 14px;
        font-weight: 600;
    }


.map-office-type {
    margin-bottom: 7px;
    color: #697482;
    font-size: 11px;
    font-weight: 500;
}


.map-office-address {
    margin-bottom: 9px;
    color: rgb(48 53 60);
    font-size: 0.8rem;
    line-height: 1.45;
}

    .map-office-address b {
        font-size: 1rem;
        color: #0d2d66;
    }

    /* PHONE / EMAIL */
    .map-office-meta {
        display: flex;
        align-items: center;
        gap: 7px;
        margin-bottom: 6px;
        color: #5e6977;
        font-size: 10px;
    }


    .map-office-meta i {
        width: 13px;
        color: #880000;
        font-size: 9px;
    }


    .map-office-meta a {
        color: #44536a;
        text-decoration: none;
    }


        .map-office-meta a:hover {
            color: #880000;
        }


/* DIRECTIONS */

.map-directions-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 3px;
    padding: 7px 11px;
    border: 1px solid #880000;
    border-radius: 5px;
    background: #ffffff;
    color: #880000;
    font-size: 9px;
    font-weight: 600;
    text-decoration: none;
}


    .map-directions-btn:hover {
        background: #880000;
        color: #ffffff;
        text-decoration: none;
    }

.gm-style .gm-style-iw-c {
    max-width: 540px !important;
    padding: 12px !important;
    border-radius: 10px !important;
    box-shadow: 0 9px 28px rgba(15, 27, 45, .18) !important;
    max-height: 550px !important;
}


.gm-style .gm-style-iw-d {
    overflow: hidden !important;
    max-height: none !important;
}

/* =========================================================
   TABLET
========================================================= */

@media (max-width: 991px) {

    .office-locator-grid {
        grid-template-columns: minmax(280px, .85fr) minmax(0, 1.4fr);
    }


    .office-locator-container {
        width: min(100% - 28px, 1400px);
    }


    #map {
        min-height: 500px;
    }
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 767px) {

    .office-locator-section {
        padding: 20px 0 45px;
    }


    .office-locator-container {
        width: calc(100% - 24px);
    }


    .office-locator-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }


    .office-locator-search {
        padding: 18px;
    }


    .office-details-panel {
        min-height: 140px;
    }


    .office-map-panel {
        padding: 12px;
    }


    .office-map-header {
        align-items: flex-start;
    }


    #map {
        height: 430px;
        min-height: 430px;
    }
}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 576px) {

    .map-office-card {
        width: 285px;
    }


    .map-office-img {
        height: 95px;
    }


    .map-office-body h5 {
        font-size: 12px;
    }


    .map-office-type {
        font-size: 9px;
    }


    .map-office-address,
    .map-office-meta {
        font-size: 9px;
    }


    .gm-style .gm-style-iw-c {
        max-width: 310px !important;
        padding: 9px !important;
    }
}

@media (max-width: 480px) {

    .office-locator-container {
        width: calc(100% - 18px);
    }


    .office-locator-search-heading h2,
    .office-map-header h2 {
        font-size: 16px;
    }


    .office-map-status {
        padding: 6px 9px;
        font-size: 9px;
    }


    #map {
        height: 380px;
        min-height: 380px;
    }
}
