.nearby-container {
    width: 100%;
    max-width: 1060px;
    margin: 0 auto;
    padding: 120px 20px 20px;
    box-sizing: border-box;
}

.nearby-header {
    margin-bottom: 22px;
}

.nearby-header .page-title {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 700;
    color: #222;
}

.nearby-description {
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
    color: #666;
}

.nearby-location-box {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 18px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    box-sizing: border-box;
}

.nearby-location-box-top {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.nearby-location-box-top .nearby-location-text {
    flex: 1;
    min-width: 0;
}

.nearby-location-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.nearby-location-text strong {
    font-size: 16px;
    font-weight: 700;
    color: #222;
}

.nearby-location-text span {
    font-size: 13px;
    line-height: 1.5;
    color: #777;
}

.nearby-location-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    width: 100%;
    min-width: 0;
    height: 48px;
    padding: 0 20px;
    border: none;
    border-radius: 9px;
    background: #f58220;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition:
        opacity 0.2s,
        transform 0.2s;
}

.nearby-location-box-top .nearby-location-btn {
    width: auto;
    min-width: 190px;
    flex-shrink: 0;
}

.nearby-location-btn:hover {
    opacity: 0.9;
}

.nearby-location-btn:active {
    transform: scale(0.98);
}

.nearby-location-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.nearby-location-btn i {
    font-size: 17px;
}

.nearby-top-panel {
    width: 100%;
    margin-bottom: 22px;
    padding: 16px 18px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    box-sizing: border-box;
}

.nearby-top-category {
    margin-bottom: 14px;
}

.nearby-category {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.nearby-category button {
    width: 100%;
    min-height: 44px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 9px;
    background: #fff;
    color: #444;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition:
        border-color 0.2s,
        background 0.2s,
        color 0.2s;
}

.nearby-category button:hover {
    border-color: #f58220;
    color: #f58220;
}

.nearby-category button.active {
    border-color: #f58220;
    background: #f58220;
    color: #fff;
}

.nearby-top-status {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 14px;
    border-top: 1px solid #eee;
}

.nearby-location-status {
    flex: 1;
    min-width: 0;
    padding: 9px 12px;
    border-radius: 8px;
    background: #f7f7f7;
    font-size: 13px;
    line-height: 1.5;
    color: #666;
}

.nearby-top-count {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 13px;
    border-radius: 8px;
    background: #fff8f2;
    font-size: 13px;
    color: #555;
}

.nearby-top-count strong {
    font-size: 15px;
    font-weight: 700;
    color: #f58220;
}

.nearby-layout {
    display: grid;
    grid-template-columns: 380px minmax(0, 1fr);
    gap: 18px;
    align-items: stretch;
    width: 100%;
}

.nearby-left-panel {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    height: 710px;
    min-height: 0;
}

.nearby-radius-wrap {
    flex-shrink: 0;
    margin-bottom: 22px;
}

.nearby-radius-title {
    margin-bottom: 9px;
    font-size: 14px;
    font-weight: 700;
    color: #333;
}

.nearby-radius {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 5px;
}

.nearby-radius button {
    width: 100%;
    min-width: 0;
    height: 38px;
    padding: 0 3px;
    border: 1px solid #ddd;
    border-radius: 20px;
    background: #fff;
    color: #555;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition:
        border-color 0.2s,
        background 0.2s,
        color 0.2s;
}

.nearby-radius button:hover {
    border-color: #f58220;
    color: #f58220;
}

.nearby-radius button.active {
    border-color: #f58220;
    background: #fff3e9;
    color: #f58220;
    font-weight: 700;
}

.nearby-result-section {
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100%;
    min-height: 0;
}

.nearby-list-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.nearby-list-header strong {
    font-size: 17px;
    font-weight: 700;
    color: #222;
}

.nearby-list-count {
    font-size: 12px;
    color: #888;
}

.nearby-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
    width: 100%;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 4px 5px 4px 4px;
    box-sizing: border-box;
}

.nearby-list::-webkit-scrollbar {
    width: 6px;
}

.nearby-list::-webkit-scrollbar-thumb {
    background: #d5d5d5;
    border-radius: 10px;
}

.nearby-list::-webkit-scrollbar-track {
    background: transparent;
}

.nearby-item {
    width: 100%;
    padding: 15px;
    box-sizing: border-box;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    transition:
        border-color 0.2s,
        box-shadow 0.2s,
        transform 0.2s;
}

.nearby-item:hover {
    border-color: #f58220;
    box-shadow: 0 2px 10px rgba(245, 130, 32, 0.12);
}

.nearby-item:active {
    transform: scale(0.995);
}

.nearby-item:focus {
    outline: 2px solid rgba(245, 130, 32, 0.3);
    outline-offset: 2px;
}

.nearby-item-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 7px;
}

.nearby-item-main {
    flex: 1;
    min-width: 0;
}

.nearby-item-type {
    display: inline-flex;
    align-items: center;
    margin-bottom: 6px;
    padding: 4px 8px;
    border-radius: 5px;
    background: #f4f4f4;
    color: #666;
    font-size: 11px;
    font-weight: 600;
}

.nearby-item-title {
    margin: 0;
    overflow: hidden;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    color: #222;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nearby-item-distance {
    flex-shrink: 0;
    padding-top: 2px;
    font-size: 13px;
    font-weight: 700;
    color: #f58220;
}

.nearby-item-company {
    margin-bottom: 6px;
    font-size: 13px;
    line-height: 1.5;
    color: #555;
}

.nearby-item-address {
    display: flex;
    align-items: flex-start;
    gap: 5px;
    font-size: 12px;
    line-height: 1.5;
    color: #777;
}

.nearby-item-address i {
    flex-shrink: 0;
    margin-top: 2px;
    color: #999;
}

.nearby-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 510px;
    padding: 30px 20px;
    border: 1px dashed #ddd;
    border-radius: 10px;
    background: #fafafa;
    text-align: center;
    color: #888;
}

.nearby-empty i {
    margin-bottom: 8px;
    font-size: 30px;
    color: #bbb;
}

.nearby-empty p {
    margin: 0;
    font-size: 14px;
    line-height: 1.7;
}

.nearby-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 520px;
    padding: 20px;
    border: 1px solid #eee;
    border-radius: 10px;
    background: #fafafa;
    font-size: 14px;
    color: #777;
}

.nearby-right-panel {
    position: static;
    display: flex;
    flex-direction: column;
    align-self: start;
    width: 100%;
    min-width: 0;
    height: 710px;
}

.nearby-map-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.nearby-map-header strong {
    font-size: 17px;
    font-weight: 700;
    color: #222;
}

.nearby-map-wrap {
    position: relative;
    flex: 1;
    width: 100%;
    min-height: 0;
    margin: 0;
    overflow: hidden;
    border-radius: 12px;
    background: #f5f5f5;
}

#nearbyMap {
    width: 100%;
    height: 100%;
}

.nearby-my-location-marker {
    position: relative;
    width: 24px;
    height: 24px;
    cursor: pointer;
}

.nearby-my-location-pulse {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 24px;
    height: 24px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.18);
}

.nearby-my-location-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 12px;
    height: 12px;
    transform: translate(-50%, -50%);
    border: 2px solid #fff;
    border-radius: 50%;
    background: #2563eb;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.35);
}

.nearby-my-location-label {
    position: absolute;
    left: 50%;
    top: 28px;
    transform: translateX(-50%);
    padding: 3px 5px;
    border-radius: 5px;
    background: #2563eb;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
}

.nearby-my-location-info {
    position: absolute;
    left: 50%;
    top: 50px;
    transform: translateX(-50%);
    width: 240px;
    max-width: calc(100vw - 40px);
    padding: 11px 12px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.18);
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    z-index: 50;
}

.nearby-my-location-info[hidden] {
    display: none;
}

.nearby-my-location-info strong {
    display: block;
    margin-bottom: 5px;
    font-size: 13px;
    font-weight: 700;
    color: #222;
}

.nearby-my-location-info span,
.nearby-my-location-info small {
    display: block;
    width: 100%;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.5;
}

.nearby-my-location-info span {
    font-size: 12px;
    color: #555;
}

.nearby-my-location-info small {
    margin-top: 4px;
    font-size: 11px;
    color: #888;
}

.nearby-map-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nearby-map-touch-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

body.postcode-modal-open {
    overflow: hidden;
}

.nearby-postcode-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.45);
}

.nearby-postcode-modal[hidden] {
    display: none !important;
}

.nearby-postcode-box {
    width: 100%;
    max-width: 500px;
    height: 600px;
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 12px;
    background: #fff;
}

.nearby-postcode-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 50px;
    padding: 0 14px;
    border-bottom: 1px solid #eee;
    background: #fff;
}

.nearby-postcode-close {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    background: transparent;
    font-size: 20px;
    cursor: pointer;
}

.nearby-postcode-layer {
    flex: 1;
    min-height: 0;
    width: 100%;
}
.nearby-item-map-target {
    width: 100%;
    cursor: pointer;
}

.nearby-item-detail-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0;
}

.nearby-item-detail-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    width: auto;
    padding: 0;
    border: 0;
    background: transparent;
    color: #f58220;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.nearby-item-detail-btn i {
    font-size: 11px;
}

.nearby-item-detail-btn:hover {
    text-decoration: underline;
}

.nearby-search-location-marker .nearby-my-location-label {
    background: #7c3aed;
}

.nearby-search-location-marker .nearby-my-location-dot {
    background: #7c3aed;
}

.nearby-search-location-marker .nearby-my-location-pulse {
    background: rgba(124, 58, 237, 0.18);
}

.nearby-map-touch-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 34px;
    padding: 0 10px;
    border: 1px solid #ddd;
    border-radius: 7px;
    background: #fff;
    color: #555;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition:
        border-color 0.2s,
        background 0.2s,
        color 0.2s;
}

.nearby-map-touch-btn:hover {
    border-color: #f58220;
    color: #f58220;
}

.nearby-map-touch-btn.active {
    border-color: #f58220;
    background: #fff3e9;
    color: #f58220;
}

.nearby-map-search-open-btn,
.nearby-location-actions .nearby-location-btn {
    display: inline-flex;
}

.nearby-search-location {
    flex: 1 1 320px;
    display: flex;
    align-items: flex-start;
    gap: 7px;
    min-width: 0;
    max-width: 420px;
    padding: 9px 12px;
    box-sizing: border-box;
    border: 1px solid #ffe0c4;
    border-radius: 8px;
    background: #fff8f2;
    font-size: 13px;
    color: #555;
}

.nearby-search-location > i {
    flex-shrink: 0;
    margin-top: 3px;
    color: #f58220;
}

.nearby-search-location-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.nearby-search-location-title {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
}

.nearby-search-location-title span {
    color: #777;
}

.nearby-search-location-title strong {
    color: #222;
}

.nearby-search-location-address {
    display: block;
    width: 100%;
    max-width: 100%;
    margin-top: 4px;
    box-sizing: border-box;
    font-size: 12px;
    line-height: 1.5;
    color: #666;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.nearby-location-notice {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    width: 100%;
    margin-top: 8px;
    padding: 9px 11px;
    box-sizing: border-box;
    border-radius: 7px;
    background: #f8f9fa;
    font-size: 11px;
    line-height: 1.5;
    color: #777;
}

.nearby-location-notice i {
    flex-shrink: 0;
    margin-top: 2px;
    color: #999;
    font-size: 12px;
}

.nearby-location-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.nearby-map-search-open-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 48px;
    padding: 0 20px;
    border: 1px solid #f58220;
    border-radius: 9px;
    background: #fff;
    color: #f58220;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}
.nearby-map-search-open-btn:hover {
    background: #fff7f0;
}

.nearby-info-window {
    position: relative;
    width: 205px;
    max-width: calc(100vw - 60px);
    padding: 11px 34px 11px 11px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
    white-space: normal;
    word-break: keep-all;
}

.nearby-info-close {
    position: absolute;
    top: 7px;
    right: 7px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #777;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}

.nearby-info-type {
    margin-bottom: 4px;
    font-size: 11px;
    font-weight: 700;
    color: #f58220;
}

.nearby-info-title {
    margin-bottom: 5px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
    color: #222;
    white-space: normal;
    word-break: keep-all;
    overflow-wrap: anywhere;
}

.nearby-info-address {
    margin-bottom: 4px;
    font-size: 12px;
    line-height: 1.5;
    color: #777;
    white-space: normal;
    word-break: keep-all;
    overflow-wrap: anywhere;
}

.nearby-info-distance {
    font-size: 12px;
    font-weight: 700;
    color: #f58220;
}

.nearby-info-detail {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    margin-top: 8px;
    padding: 5px 8px;
    box-sizing: border-box;
    border-radius: 6px;
    background: #f58220;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
}

.nearby-map-error {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    text-align: center;
    color: #888;
    font-size: 14px;
}

@media (max-width: 1100px) {
    .nearby-container {
        padding: 100px 20px 20px;
    }

    .nearby-layout {
        grid-template-columns: 380px minmax(0, 1fr);
        gap: 18px;
    }
}

@media (max-width: 768px) {
    .nearby-postcode-modal {
        padding: 12px;
    }

    .nearby-postcode-box {
        width: 100%;
        max-width: 100%;

        height: calc(100dvh - 70px);
        max-height: calc(100dvh - 70px);
    }
}

@media (max-width: 768px) {
    .nearby-search-location {
        flex: none;
        width: 100%;
        max-width: 100%;
    }
    .nearby-location-actions {
        width: 100%;
        display: flex;
        gap: 8px;
    }
    .nearby-map-search-open-btn,
    .nearby-location-actions .nearby-location-btn {
        flex: 1;
        width: 50%;
        min-width: 0;
        padding: 0 8px;
    }
}

@media (max-width: 768px) {
    .nearby-container {
        padding: 90px 14px 20px;
    }

    .nearby-header {
        margin-bottom: 18px;
    }

    .nearby-header .page-title {
        font-size: 22px;
    }

    .nearby-description {
        font-size: 13px;
    }

    .nearby-location-box-top {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
        padding: 16px;
    }

    .nearby-location-box-top .nearby-location-btn {
        width: 100%;
        min-width: 0;
    }

    .nearby-top-panel {
        padding: 14px;
    }

    .nearby-category {
        grid-template-columns: repeat(2, 1fr);
        gap: 7px;
    }

    .nearby-category button {
        min-height: 42px;
        font-size: 13px;
    }

    .nearby-top-status {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .nearby-search-location,
    .nearby-location-status {
        width: 100%;
        box-sizing: border-box;
    }

    .nearby-top-count {
        justify-content: space-between;
    }

    .nearby-layout {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }

    .nearby-left-panel,
    .nearby-right-panel {
        width: 100%;
    }

    .nearby-right-panel {
        order: 1;
        position: static;
        height: auto;
    }

    .nearby-left-panel {
        order: 2;
        height: auto;
    }

    .nearby-radius {
        grid-template-columns: repeat(5, 1fr);
        gap: 6px;
    }

    .nearby-radius button {
        height: 36px;
        padding: 0 4px;
        font-size: 12px;
    }

    .nearby-result-section {
        display: flex;
        flex-direction: column;
        width: 100%;
        min-height: 0;
    }

    .nearby-list {
        display: flex;
        flex-direction: column;
        gap: 10px;
        flex: none;
        width: 100%;
        height: 420px;
        max-height: 420px;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        scrollbar-gutter: stable;
        padding: 4px 5px 4px 4px;
        box-sizing: border-box;
    }

    .nearby-list::-webkit-scrollbar {
        width: 5px;
    }

    .nearby-list::-webkit-scrollbar-thumb {
        background: #cfcfcf;
        border-radius: 10px;
    }

    .nearby-list::-webkit-scrollbar-track {
        background: #f5f5f5;
        border-radius: 10px;
    }

    .nearby-empty {
        min-height: 100%;
        box-sizing: border-box;
    }

    .nearby-loading {
        min-height: 100%;
        box-sizing: border-box;
    }

    .nearby-item {
        padding: 14px;
    }

    .nearby-item-title {
        font-size: 15px;
    }

    .nearby-item-distance {
        font-size: 13px;
    }

    .nearby-map-wrap {
        flex: none;
        width: 100%;
        height: 340px;
        border-radius: 10px;
    }
}

@media (max-width: 480px) {
    .nearby-container {
        padding: 90px 12px 20px;
    }

    .nearby-top-panel {
        padding: 12px;
    }

    .nearby-location-box-top {
        padding: 14px;
    }

    .nearby-location-text strong {
        font-size: 15px;
    }

    .nearby-location-text span {
        font-size: 12px;
    }

    .nearby-radius button {
        font-size: 11px;
    }

    .nearby-list {
        height: 400px;
        max-height: 400px;
    }

    .nearby-map-wrap {
        height: 300px;
    }

    .nearby-item-top {
        gap: 8px;
    }

    .nearby-item-title {
        font-size: 14px;
    }

    .nearby-item-address {
        font-size: 12px;
    }
}
