#sign-builder-app {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.vb-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    border: 1px solid #e2e8f0;
}

.controls-area {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.x-row-config {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.x-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.x-tag {
    display: flex;
    align-items: center;
    background: #ffffff;
    padding: 2px 8px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.x-tag-val {
    background: transparent;
    border: none;
    min-width: 60px;
    min-height: 32px;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.x-tag button {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
    margin-left: 4px;
}

.x-tag button:hover {
    color: #ef4444;
}

/* PREVIEW GRID - Integrated Table */
.preview-grid {
    display: flex;
    flex-direction: column;
    margin-top: 1.5rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    overflow-x: auto;
}

.row {
    display: flex;
    align-items: center;
}

.cell {
    padding: 0.5rem;
}

.label-cell {
    width: 80px;
    font-weight: 600;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.label-rendered {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 4px;
    text-align: center;
    background: white;
    cursor: pointer;
    min-height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sim-track-wrapper {
    flex: 1;
    display: flex;
    align-items: stretch;
}

.sign-node-wrapper {
    width: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sign-node {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #cbd5e1;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    background: white;
}

.sign-node:hover {
    border-color: #3b82f6;
    background: #eff6ff;
}

.sign-interval {
    flex: 1;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #64748b;
    font-weight: bold;
    min-width: 40px;
}

.sign-interval:hover {
    color: #3b82f6;
}

.sim-header-spacer {
    flex: 0 0 40px;
    min-width: 40px;
}

.add-mini-btn {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: none;
    background: #10b981;
    color: white;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.add-mini-btn:hover {
    background: #059669;
}

/* Simulated Preview (Final Result) */
.sim-table {
    display: flex;
    flex-direction: column;
    width: 100%;
    border: 1px solid black;
    font-family: 'Times New Roman', serif;
    background: white;
}

.sim-row {
    display: flex;
    border-bottom: 1px solid black;
}

.sim-row:last-child {
    border-bottom: none;
}

.sim-cell {
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid black;
}

.sim-label {
    width: 80px;
    flex-shrink: 0;
}

.sim-track-wrapper {
    flex: 1;
    display: flex;
    align-items: stretch;
}

.sim-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.sim-node {
    flex: 1;
    position: relative;
    min-width: 60px;
}

.sim-interval {
    flex: 1;
    min-width: 40px;
}

.d-bar {
    height: 100%;
    width: 6px;
    border-left: 1px solid black;
    border-right: 1px solid black;
}

.ghost {
    visibility: hidden;
}