/* 波特五力模型工具面板 */
.porter5-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;
}

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

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

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

.porter5-title i { color: #7c3aed; }

.porter5-badge {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(124, 58, 237, 0.1);
    color: #6d28d9;
}

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

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

.porter5-btn:hover {
    border-color: #7c3aed;
    color: #6d28d9;
}

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

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

.porter5-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: 560px;
}

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

/* 十字布局 */
.porter5-cross {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1.15fr 1fr;
    grid-template-rows: auto auto auto;
    gap: 28px 24px;
    align-items: center;
    justify-items: center;
    min-height: 560px;
}

.porter5-arrows {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.porter5-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 280px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06);
    background: #fff;
}

.porter5-card-top    { grid-column: 2; grid-row: 1; }
.porter5-card-left   { grid-column: 1; grid-row: 2; justify-self: end; }
.porter5-card-center { grid-column: 2; grid-row: 2; max-width: 300px; }
.porter5-card-right  { grid-column: 3; grid-row: 2; justify-self: start; }
.porter5-card-bottom { grid-column: 2; grid-row: 3; }

.porter5-card-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    color: #fff;
    font-size: 0.84rem;
    font-weight: 700;
}

.porter5-card-head i {
    font-size: 1rem;
    opacity: 0.95;
    flex-shrink: 0;
}

.porter5-head-blue   { background: #2563eb; }
.porter5-head-cyan   { background: #0ea5e9; }
.porter5-head-purple { background: #7c3aed; }
.porter5-head-pink   { background: #db2777; }
.porter5-head-orange { background: #ea580c; }

.porter5-card-body {
    position: relative;
    padding: 12px 14px 32px;
    min-height: 88px;
}

.porter5-bullets {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.porter5-bullet {
    position: relative;
    padding-left: 14px;
    font-size: 0.76rem;
    line-height: 1.55;
    color: #334155;
    outline: none;
    word-break: break-word;
    cursor: text;
}

.porter5-bullet::before {
    content: '•';
    position: absolute;
    left: 0;
    top: 0;
    color: #64748b;
    font-weight: 700;
}

.porter5-bullet:empty::after {
    content: '点击输入…';
    color: #94a3b8;
}

.porter5-bullet:focus {
    box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.3);
    border-radius: 4px;
}

.porter5-btn-add {
    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.92);
    color: #64748b;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.45;
    transition: opacity 0.15s;
}

.porter5-card:hover .porter5-btn-add { opacity: 1; }

.porter5-btn-add:hover {
    border-color: #7c3aed;
    color: #6d28d9;
}
@media (max-width: 960px) {
    .porter5-board {
        min-width: 820px;
        padding: 20px 16px;
    }

    .porter5-cross {
        gap: 22px 16px;
        min-height: 520px;
    }

    .porter5-card {
        max-width: 250px;
    }

    .porter5-card-center {
        max-width: 270px;
    }
}
