.pxlsx-shell .pxlsx-toolbar {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
}

.pxlsx-shell .pxlsx-toolbar .input-group {
    width: min(460px, 100%);
}

.pxlsx-shell .pxlsx-grid-wrap {
    overflow: auto;
    max-height: calc(100vh - 280px);
    border: 1px solid #e3e7ee;
    border-radius: 8px;
    background: #fff;
}

.pxlsx-shell .pxlsx-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.pxlsx-shell .pxlsx-legend-item {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    border: 1px solid transparent;
}

.pxlsx-shell .pxlsx-legend-item.stock-good {
    background: #d9f2e1;
    border-color: #9ad3b0;
    color: #0f5132;
}

.pxlsx-shell .pxlsx-legend-item.stock-warning {
    background: #fff1b8;
    border-color: #ffe08a;
    color: #7a5b00;
}

.pxlsx-shell .pxlsx-legend-item.stock-danger {
    background: #ffd6d3;
    border-color: #f5a3a0;
    color: #842029;
}

.pxlsx-shell .pxlsx-legend-item.stock-out {
    background: #e2e3e5;
    border-color: #c6c8ca;
    color: #41464b;
}

.pxlsx-shell .pxlsx-grid {
    width: 100%;
    min-width: 980px;
    border-collapse: collapse;
    table-layout: fixed;
}

.pxlsx-shell .pxlsx-grid thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #f7f9fc;
    border-bottom: 2px solid #dbe3ef;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.55rem;
    white-space: nowrap;
}

.pxlsx-shell .pxlsx-grid tbody td {
    border-bottom: 1px solid #edf1f7;
    padding: 0;
    vertical-align: middle;
}

.pxlsx-shell .pxlsx-cell-input,
.pxlsx-shell .pxlsx-cell-select {
    border: none;
    border-radius: 0;
    width: 100%;
    padding: 0.45rem 0.5rem;
    background: transparent;
    font-size: 0.9rem;
}

.pxlsx-shell .pxlsx-cell-input:focus,
.pxlsx-shell .pxlsx-cell-select:focus {
    outline: none;
    background: #eef6ff;
    box-shadow: inset 0 0 0 2px #90c2ff;
}

.pxlsx-shell .pxlsx-cell-readonly {
    background: #f7f9fc;
    color: #495057;
}

.pxlsx-shell .pxlsx-cell-readonly:focus {
    background: #f7f9fc;
    box-shadow: none;
}

.pxlsx-shell .pxlsx-stock-input {
    width: calc(100% - 0.8rem);
    margin: 0.35rem 0.4rem 0.1rem;
    border: 1px solid transparent;
    border-radius: 999px;
    text-align: center;
    font-weight: 700;
    padding: 0.35rem 0.45rem;
}

.pxlsx-shell .pxlsx-stock-input.stock-good {
    background: #d9f2e1;
    border-color: #9ad3b0;
    color: #0f5132;
}

.pxlsx-shell .pxlsx-stock-input.stock-warning {
    background: #fff1b8;
    border-color: #ffe08a;
    color: #7a5b00;
}

.pxlsx-shell .pxlsx-stock-input.stock-danger {
    background: #ffd6d3;
    border-color: #f5a3a0;
    color: #842029;
}

.pxlsx-shell .pxlsx-stock-input.stock-out {
    background: #e2e3e5;
    border-color: #c6c8ca;
    color: #41464b;
}

.pxlsx-shell .pxlsx-row-saving {
    background: #fff8e6;
}

.pxlsx-shell .pxlsx-row-error {
    background: #ffecec;
}

.pxlsx-shell .stock-row-good td {
    background: #eef9f2;
}

.pxlsx-shell .stock-row-warning td {
    background: #fff5d6;
}

.pxlsx-shell .stock-row-danger td {
    background: #ffeaea;
}

.pxlsx-shell .stock-row-out td {
    background: #e9edf1;
}

.pxlsx-shell .pxlsx-meta {
    color: #6c757d;
    font-size: 0.82rem;
}

@media (max-width: 768px) {
    .pxlsx-shell .pxlsx-grid-wrap {
        max-height: calc(100vh - 240px);
    }
}
