/* 竞品价格监控 — 四列对标看板 */
.pm-tool-panel {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    min-height: 0;
}

.pm-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-muted, #f9fafb);
    flex-shrink: 0;
}

.pm-toolbar-left { display: flex; align-items: center; gap: 8px; }

.pm-title {
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pm-title i { color: #8b5cf6; }

.pm-badge {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(139, 92, 246, 0.1);
    color: #7c3aed;
}

.pm-toolbar-right { display: flex; align-items: center; gap: 6px; }

.pm-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 10px;
    font-size: 0.78rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    cursor: pointer;
}

.pm-btn:hover { border-color: #8b5cf6; color: #7c3aed; }

.pm-btn-primary {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    border-color: transparent;
    color: #fff !important;
}

.pm-canvas-wrap {
    flex: 1;
    overflow: auto;
    padding: 16px;
    background-color: #f3f4f6;
    background-image: radial-gradient(circle, #d1d5db 1px, transparent 1px);
    background-size: 20px 20px;
    min-height: 520px;
}

.pm-board {
    max-width: 1180px;
    margin: 0 auto;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
    padding: 24px 18px 20px;
    min-width: 760px;
}

.pm-map-header { margin-bottom: 18px; }

.pm-map-title {
    margin: 0 0 4px;
    font-size: 1.35rem;
    font-weight: 700;
    outline: none;
}

.pm-map-subtitle {
    margin: 0;
    font-size: 0.82rem;
    color: #6b7280;
    outline: none;
}

.pm-columns {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.pm-col {
    position: relative;
    background: #fafafa;
    border-radius: 12px;
    padding: 0 10px 12px;
    overflow: hidden;
}

.pm-col-accent {
    height: 5px;
    margin: 0 -10px 0;
    border-radius: 12px 12px 0 0;
}

.pm-col-own .pm-col-accent { background: #3b82f6; }
.pm-col-top .pm-col-accent { background: #14b8a6; }
.pm-col-peer .pm-col-accent { background: #f97316; }
.pm-col-plan .pm-col-accent { background: #eab308; }

.pm-col-header {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 8px 12px;
    text-align: center;
}

.pm-col-dots {
    position: absolute;
    width: 48px;
    height: 48px;
    opacity: 0.35;
    background-image: radial-gradient(circle, #cbd5e1 1.5px, transparent 1.5px);
    background-size: 8px 8px;
    pointer-events: none;
}

.pm-col-dots-tr { top: 4px; right: 4px; }
.pm-col-dots-bl { bottom: 0; left: 4px; }

.pm-col-icon-wrap {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    margin-bottom: 10px;
}

.pm-col-own .pm-col-icon-wrap { background: rgba(59, 130, 246, 0.12); color: #2563eb; }
.pm-col-top .pm-col-icon-wrap { background: rgba(20, 184, 166, 0.12); color: #0d9488; }
.pm-col-peer .pm-col-icon-wrap { background: rgba(249, 115, 22, 0.12); color: #ea580c; }
.pm-col-plan .pm-col-icon-wrap { background: rgba(234, 179, 8, 0.15); color: #ca8a04; }

.pm-col-title {
    margin: 0;
    padding: 6px 16px;
    font-size: 0.82rem;
    font-weight: 700;
    border-radius: 999px;
    color: #fff;
    outline: none;
    min-width: 72px;
}

.pm-col-own .pm-col-title { background: #3b82f6; }
.pm-col-top .pm-col-title { background: #14b8a6; }
.pm-col-peer .pm-col-title { background: #f97316; }
.pm-col-plan .pm-col-title { background: #eab308; color: #422006; }

.pm-items {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pm-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 8px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
}

.pm-item-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #fff;
}

.pm-col-own .pm-item-icon { background: #3b82f6; }
.pm-col-top .pm-item-icon { background: #14b8a6; }
.pm-col-peer .pm-item-icon { background: #f97316; }
.pm-col-plan .pm-item-icon { background: #eab308; color: #422006; }

.pm-item-body { flex: 1; min-width: 0; }

.pm-item-text {
    margin: 0 0 6px;
    font-size: 0.74rem;
    line-height: 1.45;
    color: #374151;
    outline: none;
    cursor: text;
}

.pm-item-text:focus {
    background: #f9fafb;
    border-radius: 4px;
}

.pm-rating {
    display: flex;
    gap: 4px;
    cursor: pointer;
}

.pm-rating-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #e5e7eb;
    transition: background 0.15s;
}

.pm-rating-dot.filled { background: currentColor; }

.pm-col-own .pm-rating { color: #3b82f6; }
.pm-col-top .pm-rating { color: #14b8a6; }
.pm-col-peer .pm-rating { color: #f97316; }
.pm-col-plan .pm-rating { color: #eab308; }

.pm-legend {
    display: flex;
    justify-content: center;
    gap: 28px;
    margin-top: 18px;
    padding: 10px 24px;
    background: #f9fafb;
    border-radius: 999px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.pm-legend-group {
    display: flex;
    align-items: center;
    gap: 3px;
}

.pm-legend-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #e5e7eb;
}

.pm-legend-dot-lg {
    width: 8px;
    height: 8px;
}

.pm-legend-own .pm-legend-dot { background: #3b82f6; }
.pm-legend-top .pm-legend-dot { background: #14b8a6; }
.pm-legend-peer .pm-legend-dot { background: #f97316; }
.pm-legend-plan .pm-legend-dot { background: #eab308; }

@media (max-width: 960px) {
    .pm-columns { grid-template-columns: repeat(2, 1fr); }
    .pm-legend { flex-wrap: wrap; gap: 16px; }
}

@media (max-width: 640px) {
    .pm-columns { grid-template-columns: 1fr; }
    .pm-board { min-width: 0; }
}
