/* /tools/fabric-layout-estimator/style.css */

/* --- Custom Tool Assets --- */

/* --- Forms & Inputs --- */
.ac-unit-toggle {
    margin-bottom: 1em;
}

.ac-unit-btn {
    padding: 8px 15px;
    border: 1px solid var(--color-border);
    background: var(--color-bg);
    cursor: pointer;
    color: var(--color-text-secondary);
}

.ac-unit-btn.active {
    background: var(--color-primary);
    color: #fff;
    border-color: var(--color-primary);
}

.ac-unit-btn:first-child {
    border-radius: 4px 0 0 4px;
    border-right: none;
}

.ac-unit-btn:last-child {
    border-radius: 0 4px 4px 0;
}


/* --- Piece List --- */
#actb-piece-list {
    margin-bottom: 1em;
}

.ac-piece-row {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
    background: var(--color-bg);
    padding: 10px;
    border: 1px solid var(--color-border);
    border-radius: 6px;
}

.ac-piece-name {
    flex: 2;
}

.ac-piece-dims {
    flex: 2;
    display: flex;
    align-items: center;
    gap: 5px;
}

.ac-piece-qty {
    width: 60px;
    text-align: center;
}

.ac-btn-remove {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #fee;
    background: #fff5f5;
    color: #e53e3e;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.ac-btn-remove:hover {
    background: #e53e3e;
    color: #fff;
    border-color: #e53e3e;
}


/* --- Canvas Visualizer --- */
.ac-canvas-box {
    margin-top: 2em;
    padding-top: 2em;
    border-top: 1px solid var(--color-border);
    text-align: center;
}

.ac-canvas-container {
    width: 100%;
    overflow-x: auto;
    background: #f0f0f0;
    /* Contrast against white fabric */
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--color-border);
    margin-top: 20px;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.05);
}

canvas#actb-layout-canvas {
    background: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: block;
    margin: 0 auto;
}

.ac-results-summary {
    display: inline-block;
    background: var(--color-primary);
    color: #fff;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 1.2em;
    margin-bottom: 15px;
}

.ac-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 10px;
    font-size: 0.9em;
    color: var(--color-text-secondary);
}

.ac-legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.ac-swatch {
    width: 15px;
    height: 15px;
    border-radius: 3px;
}