/* 波士顿矩阵工具面板 */
.bcg-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;
}

.bcg-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;
}

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

.bcg-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.bcg-title i { color: #ec4899; }

.bcg-badge {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(236, 72, 153, 0.1);
    color: #db2777;
}

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

.bcg-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 10px;
    font-size: 0.78rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}

.bcg-btn:hover {
    border-color: #ec4899;
    color: #db2777;
}

.bcg-btn-primary {
    background: linear-gradient(135deg, #ec4899, #f472b6);
    border-color: transparent;
    color: #fff !important;
}

.bcg-btn-primary:hover {
    opacity: 0.88;
    border-color: transparent !important;
}

.bcg-canvas-wrap {
    flex: 1;
    overflow: auto;
    padding: 16px;
    background-color: #eef1f5;
    background-image: radial-gradient(circle, #c5cdd8 1px, transparent 1px);
    background-size: 18px 18px;
    min-height: 520px;
}

.bcg-board {
    max-width: 1100px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
    padding: 24px 20px 20px;
    min-width: 900px;
}

/* 三栏：左说明 | 矩阵 | 右说明 */
.bcg-layout {
    display: grid;
    grid-template-columns: 200px 1fr 200px;
    gap: 14px;
    align-items: stretch;
}

.bcg-side-cards {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 0;
}

.bcg-def-card {
    background: #ffedd5;
    border: 1px solid #fed7aa;
    border-radius: 10px;
    padding: 12px 14px;
    position: relative;
}

.bcg-side-left .bcg-def-star::after,
.bcg-side-left .bcg-def-cow::after,
.bcg-side-right .bcg-def-question::after,
.bcg-side-right .bcg-def-dog::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 28px;
    height: 2px;
    background: linear-gradient(90deg, #fb923c, transparent);
    transform: translateY(-50%);
}

.bcg-side-left .bcg-def-star::after,
.bcg-side-left .bcg-def-cow::after {
    right: -28px;
}

.bcg-side-right .bcg-def-question::after,
.bcg-side-right .bcg-def-dog::after {
    left: -28px;
    background: linear-gradient(270deg, #fb923c, transparent);
}

.bcg-def-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #c2410c;
    margin-bottom: 6px;
}

.bcg-def-body {
    font-size: 0.72rem;
    line-height: 1.55;
    color: #78350f;
    outline: none;
    word-break: break-word;
}

.bcg-def-body:empty::before {
    content: '点击输入说明…';
    color: #fdba74;
}

.bcg-def-body:focus {
    box-shadow: 0 0 0 2px rgba(251, 146, 60, 0.35);
    border-radius: 4px;
}

/* 矩阵区域 */
.bcg-matrix-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.bcg-y-axis-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-size: 0.72rem;
    font-weight: 600;
    color: #475569;
}

.bcg-y-axis-label i {
    font-size: 1.1rem;
    color: #64748b;
}

.bcg-x-axis-label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 600;
    color: #475569;
    margin-top: 4px;
}

.bcg-x-axis-label i {
    font-size: 1.1rem;
    color: #64748b;
}

.bcg-matrix-inner {
    position: relative;
    width: 100%;
}

.bcg-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
    min-height: 440px;
    position: relative;
    z-index: 1;
}

/* 十字轴与中心圆 */
.bcg-axis-cross {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bcg-axis-v,
.bcg-axis-h {
    position: absolute;
    background: #94a3b8;
}

.bcg-axis-v {
    left: 50%;
    top: 8%;
    bottom: 8%;
    width: 2px;
    transform: translateX(-50%);
}

.bcg-axis-h {
    top: 50%;
    left: 8%;
    right: 8%;
    height: 2px;
    transform: translateY(-50%);
}

/* 象限 */
.bcg-quadrant {
    position: relative;
    border-radius: 10px;
    border: 1.5px solid transparent;
    padding: 10px 12px 30px;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: rgba(255, 255, 255, 0.55);
}

.bcg-q-star {
    background: #faf5ff;
    border-color: #e9d5ff;
}

.bcg-q-question {
    background: #f0f9ff;
    border-color: #bae6fd;
}

.bcg-q-cow {
    background: #f0fdfa;
    border-color: #99f6e4;
}

.bcg-q-dog {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.bcg-q-icon {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 1.25rem;
    line-height: 1;
    opacity: 0.9;
}

.bcg-q-head {
    font-size: 0.84rem;
    font-weight: 700;
    margin-bottom: 8px;
    flex-shrink: 0;
    padding-right: 28px;
}

.bcg-q-head em {
    font-style: normal;
    font-weight: 500;
    font-size: 0.68rem;
    color: #64748b;
    display: block;
    margin-top: 1px;
}

.bcg-head-amber { color: #d97706; }
.bcg-head-blue  { color: #2563eb; }
.bcg-head-teal  { color: #0d9488; }
.bcg-head-slate { color: #475569; }

.bcg-notes {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    min-height: 0;
}

.bcg-notes-purple .bcg-note {
    background: #e0e7ff;
    border-color: #c7d2fe;
}

.bcg-notes-blue .bcg-note {
    background: #e0f2fe;
    border-color: #bae6fd;
}

.bcg-note {
    padding: 7px 9px;
    border-radius: 6px;
    font-size: 0.74rem;
    line-height: 1.45;
    color: #1e293b;
    border: 1px solid rgba(148, 163, 184, 0.3);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
    outline: none;
    cursor: text;
    word-break: break-word;
}

.bcg-note strong {
    font-weight: 600;
    color: #334155;
}

.bcg-note:empty::before {
    content: '点击输入…';
    color: #94a3b8;
}

.bcg-note:focus {
    box-shadow: 0 0 0 2px rgba(236, 72, 153, 0.35);
}

.bcg-btn-add-note {
    position: absolute;
    right: 8px;
    bottom: 6px;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 1px dashed #cbd5e1;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.9);
    color: #64748b;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.55;
    transition: opacity 0.15s;
}

.bcg-quadrant:hover .bcg-btn-add-note { opacity: 1; }

.bcg-btn-add-note:hover {
    border-color: #ec4899;
    color: #db2777;
}
@media (max-width: 960px) {
    .bcg-board {
        min-width: 820px;
        padding: 16px 14px;
    }

    .bcg-layout {
        grid-template-columns: 170px 1fr 170px;
        gap: 10px;
    }

    .bcg-grid {
        min-height: 380px;
    }
}
