﻿
html, body {
    font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Helvetica Neue', 'Segoe UI', Roboto, 'Noto Sans CJK SC', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html, body, #map {
    height: 100%;padding:0;margin:0
}
.header {
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 99999;
    background: #DCDFE6;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 5px;
    box-sizing: border-box;
    color: #fff;
}

.header-stats {
    position: absolute;
    top: 44px;
    left: 8px;
    z-index: 99990;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 12px;
}
#app {
    background: #fff;
    overflow: hidden;
    padding-bottom: 30px;
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 1001;
    height: 100%;
}


#map {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    
}


.datainfo {
    z-index: 999;
    background: rgba(0, 0, 0, 0.6);
    position:fixed;
    left:0;
    right:0;
    bottom:0;
    font-size:14px;
    padding:8px 10px;
    color:#fff;
    display:flex;
    align-items:center;
    gap:6px;
    flex-wrap:wrap;
}
.datainfo-gps {
    font-weight: 600;
    font-size: 13px;
    padding: 1px 7px;
    border-radius: 10px;
    white-space: nowrap;
}
.datainfo-gps.gps-good  { background: rgba(103,194,58,0.25); color: #85e04a; }
.datainfo-gps.gps-ok    { background: rgba(230,162,60,0.25); color: #f5c518; }
.datainfo-gps.gps-poor  { background: rgba(245,108,108,0.25); color: #ff7070; }
.datainfo-notice { font-size:13px; color:rgba(255,255,255,0.85); }

.locating-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 8px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    vertical-align: -2px;
    animation: locating-spin 0.8s linear infinite;
}

@keyframes locating-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.nearby-legend {
    position: fixed;
    right: 10px;
    top: 52px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    border-radius: 8px;
    padding: 8px 10px;
    max-width: 260px;
    font-size: 12px;
    line-height: 1.4;
}

.chat-toggle-btn {
    position: fixed;
    right: 12px;
    bottom: 138px;
    z-index: 1000;
}
.chat-unread-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    background: #f56c6c;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    pointer-events: none;
}

.report-toggle-btn {
    position: fixed;
    right: 12px;
    bottom: 200px;
    z-index: 1000;
    color: #555;
}

.report-toggle-btn.is-active {
    color: #409EFF;
    border-color: #409EFF;
}

.report-panel {
    position: fixed;
    right: 10px;
    bottom: 130px;
    z-index: 1100;
    width: 300px;
    max-height: 65vh;
    background: rgba(18, 20, 28, 0.88);
    color: #fff;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.report-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    background: rgba(0,0,0,0.25);
    flex-shrink: 0;
}

/* 反馈模式提示条 */
.report-mode-hint {
    font-size: 12px;
    padding: 6px 14px;
    flex-shrink: 0;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.report-mode-hint.hint-pin {
    background: rgba(245,108,108,0.18);
    color: #ffb3b3;
    border-left: 3px solid #f56c6c;
}
.report-mode-hint.hint-gps {
    background: rgba(64,158,255,0.15);
    color: #a8d4ff;
    border-left: 3px solid #409EFF;
}

/* 地图浮动 toast 提示 */
.map-toast {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.75);
    color: #fff;
    font-size: 14px;
    padding: 8px 18px;
    border-radius: 20px;
    z-index: 2000;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 2px 12px rgba(0,0,0,0.4);
    animation: toast-fadein 0.2s ease;
}
@@keyframes toast-fadein {
    from { opacity: 0; transform: translateX(-50%) translateY(8px); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.report-form {
    padding: 12px 14px;
    overflow-y: auto;
    flex: 1;
}

.report-location-row {
    font-size: 12px;
    color: rgba(255,255,255,0.65);
    margin-bottom: 10px;
    padding: 6px 8px;
    background: rgba(255,255,255,0.06);
    border-radius: 5px;
}

.report-textarea {
    min-height: 72px;
    margin-bottom: 8px !important;
}

.report-photo-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.report-photo-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.75);
    border-radius: 5px;
    padding: 5px 10px;
    font-size: 12px;
    cursor: pointer;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.report-photo-btn:hover {
    background: rgba(255,255,255,0.18);
}

.report-photo-clear {
    border: 0;
    background: rgba(245,108,108,0.25);
    color: rgba(255,100,100,0.9);
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    flex-shrink: 0;
}

.report-success {
    padding: 28px 14px;
    text-align: center;
    font-size: 14px;
}

.report-success-icon {
    font-size: 40px;
    color: #67C23A;
    margin-bottom: 10px;
}

.track-toggle-btn {
    position: fixed;
    right: 10px;
    bottom: 174px;
    z-index: 1000;
    border: 0;
    border-radius: 6px;
    background: #F56C6C;
    color: #fff;
    padding: 8px 12px;
    cursor: pointer;
}

.track-panel {
    position: fixed;
    right: 10px;
    bottom: 214px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    border-radius: 8px;
    padding: 8px 10px;
    font-size: 12px;
    line-height: 1.4;
}

.donate-toggle-btn {
    position: fixed;
    right: 10px;
    bottom: 126px;
    z-index: 1000;
}

.map-tool-btn {
    width: 54px;
    height: 54px;
    border: 1px solid #e6e9ef;
    border-radius: 14px;
    background: #fff;
    color: #222;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.map-tool-btn.is-active {
    border-color: #6aa7ff;
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.18), 0 4px 12px rgba(0, 0, 0, 0.2);
}

.tool-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    margin-top: 0;
}

.tool-icon-chat {
    border: 2px solid #111;
    border-radius: 6px;
    width: 18px;
    height: 12px;
    position: relative;
    box-sizing: border-box;
}

.tool-icon-chat::after {
    content: "";
    position: absolute;
    left: 3px;
    bottom: -5px;
    width: 6px;
    height: 6px;
    border-left: 2px solid #111;
    border-bottom: 2px solid #111;
    transform: skewY(-20deg) rotate(-10deg);
    background: #fff;
}

.recenter-btn {
    position: fixed;
    left: 12px;
    bottom: 138px;
    z-index: 1000;
    border: 1px solid #e6e9ee;
    border-radius: 14px;
    background: #fff;
    color: #111;
    width: 54px;
    height: 54px;
    padding: 0;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.recenter-icon {
    display: block;
    color: #444;
}

.recenter-btn.compass-mode .recenter-icon {
    color: #409EFF;
}


.donate-panel {
    position: fixed;
    right: 10px;
    bottom: 130px;
    z-index: 1000;
    width: 280px;
    background: rgba(0, 0, 0, 0.78);
    color: #fff;
    border-radius: 8px;
    padding: 10px;
    box-sizing: border-box;
}

.donate-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}

.donate-text {
    font-size: 12px;
    line-height: 1.5;
    margin-bottom: 6px;
}

.donate-qr {
    width: 180px;
    max-width: 100%;
    border-radius: 6px;
    display: block;
    margin-top: 6px;
    margin-left: auto;
    margin-right: auto;
    cursor: zoom-in;
}

.donate-qr-tip {
    margin-top: 6px;
    text-align: center;
    font-size: 12px;
    color: #dcdfe6;
}

.qr-preview-mask {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(0, 0, 0, 0.72);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    box-sizing: border-box;
}

.qr-preview-box {
    width: min(92vw, 420px);
    background: #ffffff;
    border-radius: 12px;
    padding: 14px;
    text-align: center;
}

.qr-preview-img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.qr-preview-tip {
    margin-top: 8px;
    font-size: 13px;
    color: #333;
}

.qr-preview-close {
    margin-top: 10px;
    border: 0;
    border-radius: 6px;
    background: #409EFF;
    color: #fff;
    padding: 7px 16px;
    cursor: pointer;
}

.chat-panel {
    position: fixed;
    right: 10px;
    bottom: 130px;
    z-index: 1000;
    width: 320px;
    max-height: 62vh;
    background: rgba(18, 20, 28, 0.88);
    color: #fff;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.chat-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    background: rgba(0,0,0,0.25);
    flex-shrink: 0;
}

.chat-hide-btn,
.chat-send-btn,
.chat-mini-btn {
    border: 0;
    border-radius: 5px;
    color: #fff;
    padding: 4px 10px;
    cursor: pointer;
    font-size: 12px;
}

.chat-hide-btn { background: rgba(255,255,255,0.15); }
.chat-send-btn { background: #409EFF; }
.chat-mini-btn { background: #909399; }

.chat-reply-btn {
    border: 0;
    border-radius: 4px;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
    padding: 1px 6px;
    cursor: pointer;
    font-size: 13px;
    line-height: 1.4;
}

.chat-reply-btn:hover {
    background: rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.9);
}

.chat-delete-btn {
    border: 0;
    border-radius: 4px;
    background: rgba(255,255,255,0.1);
    color: rgba(255,100,100,0.75);
    padding: 2px 8px;
    cursor: pointer;
    font-size: 11px;
}

.chat-delete-btn:hover {
    background: rgba(245,108,108,0.25);
    color: rgba(255,100,100,1);
}

.chat-list {
    padding: 0;
    overflow-y: auto;
    min-height: 80px;
    flex: 1;
}

/* 每组（主留言 + 回复）之间有明确间隔 */
.chat-group {
    border-bottom: 1px solid rgba(255,255,255,0.13);
    margin-bottom: 2px;
}

.chat-group:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

/* 主留言 */
.chat-item {
    padding: 10px 14px 8px;
}

/* 回复条目：缩进 + 左边框区分 */
.chat-reply-item {
    padding: 7px 14px 7px 16px;
    border-left: 2px solid rgba(64,158,255,0.4);
    margin: 0 10px 0 16px;
    background: rgba(255,255,255,0.04);
    border-radius: 0 4px 4px 0;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.chat-reply-item:last-child {
    border-bottom: none;
    margin-bottom: 6px;
}

.chat-meta {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    margin-bottom: 3px;
}

.chat-user {
    color: #ffe58f;
    font-weight: 600;
    font-size: 12px;
}

.chat-admin-badge {
    background: rgba(64,158,255,0.18);
    border: 1px solid rgba(64,158,255,0.4);
    color: #7ec8ff;
    border-radius: 4px;
    padding: 1px 6px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.chat-time {
    margin-left: auto;
    opacity: 0.45;
    font-size: 10px;
    font-variant-numeric: tabular-nums;
}

.chat-content {
    white-space: pre-wrap;
    word-break: break-word;
    font-size: 13px;
    line-height: 1.55;
    color: rgba(255,255,255,0.9);
}

.chat-media {
    margin-top: 8px;
}

.chat-media-thumb,
.chat-compose-thumb {
    display: block;
    width: min(100%, 220px);
    max-height: 220px;
    object-fit: cover;
    border-radius: 8px;
    cursor: zoom-in;
    box-shadow: 0 4px 14px rgba(0,0,0,0.22);
}

.chat-media-video-wrap {
    position: relative;
    width: min(100%, 220px);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0,0,0,0.22);
}

.chat-media-video,
.chat-compose-video {
    display: block;
    width: 100%;
    max-height: 240px;
    background: rgba(0,0,0,0.5);
    border-radius: 8px;
}

.chat-media-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 28px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.45);
    pointer-events: none;
}

.chat-item-actions {
    display: flex;
    gap: 6px;
    margin-top: 5px;
}

.chat-empty {
    text-align: center;
    opacity: 0.6;
    padding: 16px 8px;
    font-size: 13px;
}

.chat-form {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 10px 12px;
    background: rgba(0,0,0,0.2);
    flex-shrink: 0;
}

/* 回复横幅 */
.chat-reply-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(64,158,255,0.15);
    border-left: 3px solid #409EFF;
    border-radius: 4px;
    padding: 4px 8px;
    margin-bottom: 7px;
    font-size: 12px;
    color: rgba(255,255,255,0.9);
}

.chat-cancel-reply {
    border: 0;
    background: transparent;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    padding: 0 4px;
    font-size: 15px;
    line-height: 1;
}

.chat-input,
.chat-textarea {
    width: 100%;
    box-sizing: border-box;
    border: 0;
    border-radius: 5px;
    padding: 6px 9px;
    margin-bottom: 6px;
    font-size: 13px;
    background: rgba(255,255,255,0.92);
    color: #333;
}

.chat-textarea {
    min-height: 54px;
    resize: vertical;
}

.chat-admin-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    margin-bottom: 6px;
}

.chat-admin-auth {
    margin-bottom: 6px;
}

.chat-actions {
    display: flex;
    justify-content: flex-end;
}

.chat-media-toolbar {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.chat-media-picker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 12px;
    background: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.85);
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-media-picker:hover {
    background: rgba(255,255,255,0.18);
}

.chat-media-clear {
    border: 0;
    border-radius: 4px;
    background: rgba(245,108,108,0.24);
    color: #ff8d8d;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
}

.chat-media-compose-preview {
    margin-bottom: 8px;
}

.chat-error {
    color: #fbc4c4;
    margin-top: 5px;
    font-size: 12px;
}

.chat-preview-mask {
    position: fixed;
    inset: 0;
    z-index: 1300;
    background: rgba(0,0,0,0.82);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    box-sizing: border-box;
}

.chat-preview-box {
    width: min(94vw, 820px);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.chat-preview-image,
.chat-preview-video {
    max-width: 100%;
    max-height: calc(92vh - 56px);
    border-radius: 10px;
    background: #111;
}

.chat-preview-close {
    border: 0;
    border-radius: 6px;
    background: #409EFF;
    color: #fff;
    padding: 8px 18px;
    cursor: pointer;
}

.nearby-legend-title {
    font-weight: 600;
    margin-bottom: 6px;
}

.nearby-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
    cursor: pointer;
    border-radius: 4px;
    padding: 2px 4px;
}

.nearby-legend-item:last-child {
    margin-bottom: 0;
}

.nearby-legend-item.is-active {
    background: rgba(255, 255, 255, 0.22);
}

.nearby-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.nearby-legend-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
    
.select2box {
    z-index: 999;
    flex: 1 1 100%;
    min-width: 0;
    width: auto;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

.select2box .el-select {
    width: 100% !important;
}
.el-scrollbar .el-scrollbar__bar {
    opacity: 1 !important;
}

@media (max-width: 768px) {
    .header {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }

    .select2box {
        width: 100%;
        padding: 0;
    }

    .header-stats {
        top: 84px;
        left: 6px;
        right: 6px;
    }

    .nearby-legend {
        top: 74px;
        right: 6px;
        left: 6px;
        max-width: none;
    }

    .chat-toggle-btn {
        right: 8px;
        bottom: 120px;
    }

    .report-toggle-btn {
        right: 8px;
        bottom: 182px;
    }

    .report-panel {
        right: 6px;
        left: 6px;
        width: auto;
        bottom: 112px;
        max-height: 62vh;
    }

    .track-toggle-btn {
        right: 6px;
        bottom: 156px;
    }

    .donate-toggle-btn {
        right: 6px;
        bottom: 108px;
    }

    .recenter-btn {
        left: 8px;
        bottom: 120px;
        width: 50px;
        height: 50px;
        border-radius: 12px;
    }


    .track-panel {
        right: 6px;
        left: 6px;
        bottom: 196px;
    }

    .donate-panel {
        right: 6px;
        left: 6px;
        width: auto;
        bottom: 116px;
    }

    .chat-panel {
        right: 6px;
        left: 6px;
        width: auto;
        bottom: 112px;
        max-height: 60vh;
    }
}
