/* GROW 模型工具面板 */
.grow-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;
}

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

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

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

.grow-title i { color: #10b981; }

.grow-badge {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
}

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

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

.grow-btn:hover {
    border-color: #10b981;
    color: #059669;
}

.grow-btn-primary {
    background: linear-gradient(135deg, #10b981, #059669);
    border-color: transparent;
    color: #fff !important;
}

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

.grow-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: 480px;
}

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

.grow-map-header {
    margin-bottom: 20px;
    padding: 0 4px;
}

.grow-map-title {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 700;
    color: #111827;
    outline: none;
    line-height: 1.3;
}

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

.grow-map-title:focus,
.grow-map-subtitle:focus,
.grow-col-name:focus,
.grow-col-desc:focus {
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.35);
    border-radius: 4px;
}

/* 四列布局 */
.grow-columns {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.grow-col {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 360px;
    border-radius: 12px;
    padding: 16px 14px 36px;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.grow-col-g { background: linear-gradient(180deg, #ecfdf5 0%, #f0fdf4 100%); }
.grow-col-r { background: linear-gradient(180deg, #eff6ff 0%, #f0f9ff 100%); }
.grow-col-o { background: linear-gradient(180deg, #f0fdf4 0%, #ecfccb 100%); }
.grow-col-w { background: linear-gradient(180deg, #eef2ff 0%, #f5f3ff 100%); }

.grow-col-head {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
    flex-shrink: 0;
}

.grow-letter {
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1;
    flex-shrink: 0;
    user-select: none;
}

.grow-letter-g { color: #059669; }
.grow-letter-r { color: #2563eb; }
.grow-letter-o { color: #65a30d; }
.grow-letter-w { color: #6366f1; }

.grow-col-titles {
    flex: 1;
    min-width: 0;
    padding-top: 4px;
}

.grow-col-name {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 700;
    color: #111827;
    outline: none;
    line-height: 1.35;
}

.grow-col-desc {
    margin: 4px 0 0;
    font-size: 0.72rem;
    color: #6b7280;
    line-height: 1.45;
    outline: none;
}

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

.grow-note {
    position: relative;
    padding: 8px 10px 8px 18px;
    font-size: 0.78rem;
    line-height: 1.5;
    color: #1f2937;
    background: rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    outline: none;
    cursor: text;
    word-break: break-word;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.grow-note::before {
    content: '•';
    position: absolute;
    left: 8px;
    top: 8px;
    font-weight: 700;
    color: #64748b;
}

.grow-col-g .grow-note::before { color: #059669; }
.grow-col-r .grow-note::before { color: #2563eb; }
.grow-col-o .grow-note::before { color: #65a30d; }
.grow-col-w .grow-note::before { color: #6366f1; }

.grow-note:empty::before {
    content: '• 点击输入…';
    color: #94a3b8;
    font-weight: 400;
}

.grow-note:focus {
    background: #fff;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.3);
}

.grow-note-action {
    font-weight: 500;
}

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

.grow-col:hover .grow-btn-add-note { opacity: 1; }

.grow-btn-add-note:hover {
    border-color: #10b981;
    color: #059669;
}
@media (max-width: 960px) {
    .grow-columns {
        grid-template-columns: repeat(2, 1fr);
    }

    .grow-board {
        min-width: 560px;
    }
}

@media (max-width: 640px) {
    .grow-columns {
        grid-template-columns: 1fr;
    }

    .grow-col {
        min-height: 240px;
    }
}
