/* PRTS 地图区域页样式 — [prts_region] */
.pf-prts-region {
    width: 100%;
    overflow-x: hidden;
    user-select: none;
    -webkit-user-select: none;
}

.pf-prts-region,
.pf-prts-region :not(.pf-region-squad__locations) {
    scrollbar-width: none;
}

.pf-prts-region::-webkit-scrollbar,
.pf-prts-region :not(.pf-region-squad__locations)::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
}

.pf-region-map {
    position: relative;
    width: 100%;
    user-select: none;
    -webkit-user-drag: none;
}

.pf-region-map__image {
    display: block;
    width: 100%;
    height: auto;
    -webkit-user-drag: none;
    user-select: none;
}

.pf-region-map__image[loading="lazy"] {
    background-color: #1a1a1a;
    background-image: linear-gradient(90deg,
            #1a1a1a 25%,
            #2a2a2a 50%,
            #1a1a1a 75%);
    background-size: 200% 100%;
    animation: pf-skeleton-shimmer 1.8s ease-in-out infinite;
    min-height: 200px;
}

.pf-region-map__image.pf-loaded {
    animation: none;
    background-image: none;
}

.pf-region-map__marker {
    position: absolute;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 3px solid;
    background: #fff;
    pointer-events: auto;
    cursor: pointer;
    transform: translate(-50%, -50%);
    transition: transform 0.15s;
}

.pf-region-map__marker:hover {
    transform: translate(-50%, -50%) scale(1.3);
}

.pf-region-map__marker.active {
    transform: translate(-50%, -50%) scale(1.3);
}

.pf-region-map__marker::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid;
    border-color: currentColor;
    opacity: 0;
}

.pf-region-map__marker.active::after {
    animation: pf-marker-ripple 1.2s ease-out infinite;
}

.pf-region-map__tooltip {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 0;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
}

.pf-region-map__marker:hover .pf-region-map__tooltip,
.pf-region-map__marker.active .pf-region-map__tooltip {
    opacity: 1;
}

@keyframes pf-marker-ripple {
    0% {
        inset: -4px;
        opacity: 0.8;
        border-color: currentColor;
    }

    100% {
        inset: -18px;
        opacity: 0;
        border-color: transparent;
    }
}

.pf-region-map__mask {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s;
}

.pf-region-map__mask.active {
    opacity: 1;
}

.pf-region-squads {
    margin-top: 28px;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 8px;
    padding-bottom: 4px;
}

.pf-region-squad__wrap {
    flex: 0 0 304px;
    box-sizing: border-box;
    border: 2px solid #222222;
    background: #1C1C1C;
    position: relative;
    padding: 8px;
    z-index: 0;
}

.pf-region-squad__wrap.expanded {
    flex: 0 0 auto;
    width: fit-content;
    max-width: 100%;
    overflow: visible;
    overflow-y: hidden;
    padding: 8px;
}

.pf-region-squad__wrap.expanded.border-lit {
    border-color: #ffffff;
}

.pf-region-squad {
    display: flex;
    background: #333333;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
}

.pf-region-squad__left {
    flex: 0 0 48px;
    aspect-ratio: 1;
    background: #333333;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pf-region-squad__icon {
    width: 30px;
    height: 30px;
    object-fit: contain;
    filter: invert(0.9);
}

.pf-region-squad__right {
    flex: 1;
    padding: 0 8px;
}

.pf-region-squad__name {
    font-size: 20px;
    color: #fff;
    font-weight: 700;
    line-height: 48px;
    white-space: nowrap;
}

.pf-region-squad__members {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pf-region-squad__member {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 13px;
    color: #ddd;
    border-radius: 0;
}

.pf-region-squad__member--leader {
    border-color: #E6C922;
    background: rgba(230, 201, 34, 0.15);
    color: #fff;
    font-weight: 700;
}

.pf-region-squad__empty {
    color: #888;
    font-style: italic;
    font-size: 13px;
}

.pf-region-squad__arrow {
    flex: 0 0 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 10px;
    cursor: pointer;
    background: #4B4B4B;
    will-change: transform;
}

.pf-region-squad__arrow:hover {
    color: #fff;
    background: #5B5B5B;
}

.pf-region-squad__arrow.open {
    transform: rotate(180deg);
}

.pf-region-squad__expand {
    display: none;
    overflow: visible;
    overflow-y: hidden;
    padding-top: 8px;
}

.pf-region-squad__locations {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 8px;
    padding: 0;
    overflow: hidden;
    width: max-content;
    min-width: 0;
}

.pf-region-squad__loc {
    flex: 0 0 304px;
    width: 304px;
    min-width: 304px;
    padding: 0;
}

.pf-region-squad__loc-head {
    display: flex;
    align-items: stretch;
    gap: 8px;
    margin-bottom: 8px;
}

.pf-region-squad__loc-symbol {
    flex: 0 0 27px;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #fff;
    font-weight: 700;
}

.pf-region-squad__loc-name {
    flex: 1;
    background: #fff;
    color: #333;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    padding: 0 8px;
}

.pf-region-squad__loc-ops {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pf-region-squad__loc-card {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 2px;
}

.pf-region-squad__loc-card-left {
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pf-region-squad__loc-card-job {
    flex: 0 0 20px;
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pf-region-squad__loc-job-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: invert(0.9);
}

.pf-region-squad__loc-avatar {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.pf-region-squad__loc-avatar--fallback {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
}

.pf-region-squad__loc-card-body {
    flex: 1;
    min-width: 0;
}

.pf-region-squad__loc-card-name {
    font-size: 24px;
    color: #fff;
    font-weight: bolder;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    line-height: 32px;
}

.pf-region-squad__loc-card-code {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    line-height: 18px;
    letter-spacing: 1px;
}

.pf-region-squad__loc-card-meta {
    flex: 0 0 auto;
    display: flex;
    align-items: flex-end;
    gap: 4px;
}

.pf-region-squad__loc-card--leader .pf-region-squad__loc-card-name,
.pf-region-squad__loc-card--leader .pf-region-squad__loc-card-code {
    color: #323232;
    text-shadow: none;
}

.pf-region-squad__loc-leader {
    font-size: 14px;
    color: #313131;
    font-weight: bolder;
    line-height: 14px;
}

.pf-region-squad__loc-num {
    font-size: 12px;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    background: rgba(0, 0, 0, 0.2);
    padding: 0 6px;
    position: relative;
    left: 2px;
    top: 2px;
    font-weight: bolder;
}

.pf-region-squad__expand-empty {
    padding: 16px;
    color: #888;
    font-style: italic;
    font-size: 13px;
    text-align: center;
}

@keyframes pf-loc-enter {
    from {
        opacity: 0;
        transform: scale(0.85);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pf-card-enter {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pf-skeleton-shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

@media (max-width: 768px) {
    .pf-prts-region-map {
        max-height: 250px;
    }

    .pf-region-map__marker {
        width: 12px;
        height: 12px;
        border-width: 2px;
    }

    .pf-region-map__tooltip {
        font-size: 10px;
        padding: 2px 6px;
    }

    .pf-region-squads {
        gap: 10px;
    }

    .pf-region-squad__wrap {
        max-width: 100%;
    }

    .pf-region-squad__name {
        font-size: 16px;
        line-height: 40px;
    }

    .pf-region-squad__left {
        flex: 0 0 40px;
    }

    .pf-region-squad__icon {
        width: 24px;
        height: 24px;
    }

    .pf-region-squad__arrow {
        flex: 0 0 28px;
    }

    .pf-region-squad__locations {
        flex-wrap: wrap;
        overflow-x: visible;
    }

    .pf-region-squad__loc {
        flex: 1 1 auto;
        width: 100%;
    }

    .pf-region-squad__loc-card {
        flex-wrap: wrap;
    }

    .pf-region-squad__loc-head {
        flex-wrap: wrap;
    }
}