/* marker-info.css
   EVmorning 充電樁地圖 marker — 共用 CSS for SVG inline + data URI
   結構:
       [top bubble]      電價/度
   [left pill] [⚡中心] [right pill]
              [pin tail]
   配色:var(--brand #1f9d3e), warn #d04545, muted #7a8a7c
*/

/* 包裝元素(Home.php MapKit element 用,ChargeMap 走 SVG data URI 不需要) */
.marker_info {
    position: relative;
    width: 180px;
    height: 110px;
    pointer-events: auto;
    font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", "Microsoft JhengHei", sans-serif;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
}

/* center bolt circle */
.marker_info_center {
    position: absolute;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1f9d3e 0%, #157a2e 100%);
    box-shadow:
        0 3px 10px rgba(31, 157, 62, 0.35),
        inset 0 -3px 4px rgba(0, 0, 0, 0.12),
        inset 0 2px 3px rgba(255, 255, 255, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.marker_info_center svg {
    width: 30px;
    height: 30px;
    fill: #ffffff;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.18));
}

/* top / left / right bubbles */
.marker_info_top,
.marker_info_left,
.marker_info_right {
    position: absolute;
    background: #ffffff;
    color: #1f9d3e;
    border: 1.5px solid #1f9d3e;
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
    z-index: 1;
}

.marker_info_top {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.marker_info_left {
    top: 48px;
    left: 0;
    background: #1f9d3e;
    color: #ffffff;
    border-color: #1f9d3e;
}

.marker_info_right {
    top: 48px;
    right: 0;
}

/* pin tail */
.marker_info_pin {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 10px solid #1f9d3e;
    z-index: 1;
}

/* ===== Variant: empty (no available chargers) ===== */
.marker_info.is_empty .marker_info_center {
    background: linear-gradient(135deg, #aab5ac 0%, #5d6d5f 100%);
    box-shadow:
        0 3px 10px rgba(122, 138, 124, 0.35),
        inset 0 -3px 4px rgba(0, 0, 0, 0.12),
        inset 0 2px 3px rgba(255, 255, 255, 0.18);
}

.marker_info.is_empty .marker_info_pin {
    border-top-color: #7a8a7c;
}

.marker_info.is_empty .marker_info_left {
    background: #7a8a7c;
    border-color: #7a8a7c;
}

.marker_info.is_empty .marker_info_right {
    color: #d04545;
    border-color: #d04545;
}

/* ===== Variant: missing type (Unknown station) ===== */
.marker_info.is_unknown .marker_info_left {
    display: none;
}
