:root {
    --inventory-border-radius: 8px;
    --inventory-box-shadow: var(--drop-shadow);
    --inventory-transition: all 0.3s ease;
}
.bpo .inventory-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    background: var(--main-background);
    color: var(--main-text-color);
}

.bpo .inventory-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 25px;
    background: linear-gradient(135deg, var(--main-text-color), var(--main-button-color));
    color: var(--main-button-text-color);
    border-radius: var(--inventory-border-radius);
    box-shadow: var(--inventory-box-shadow);
}

.bpo .inventory-title {
    font-size: 2.2rem;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--main-button-text-color);
}

.bpo .inventory-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    color: var(--main-button-text-color);
}

.bpo .inventory-footer {
    text-align: center;
    margin-top: 30px;
    padding: 20px;
    color: var(--main-text-sub-color);
    font-size: 0.9rem;
}

.bpo .inventory-tabs {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, var(--main-background) 0%, var(--main-sub-background-filled) 100%);
    border-radius: 12px 12px 0 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    width: fit-content;
}

.bpo .inventory-tabs-left {
    display: flex;
    gap: 4px;
    background: var(--main-sub-background-filled);
    padding: 4px;
    border-radius: 8px 8px 0 0;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.bpo .inventory-tabs-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bpo .inventory-tab {
    padding: 12px 24px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 200px;
    text-align: center;
    background: transparent;
    color: var(--main-text-color);
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
}

.bpo .inventory-tab::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.bpo .inventory-tab:hover::before {
    left: 100%;
}

.bpo .inventory-tab:hover {
    background: linear-gradient(135deg, var(--main-hover-interact) 0%, rgba(52, 152, 219, 0.1) 100%);
    color: var(--main-button-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.2);
    border-color: rgba(52, 152, 219, 0.3);
}

.bpo .inventory-tab.active {
    background: linear-gradient(135deg, var(--main-button-color) 0%, #2980b9 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(52, 152, 219, 0.3);
    transform: translateY(-2px);
    border-color: var(--main-button-color);
}

.bpo .inventory-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 3px;
    background: linear-gradient(90deg, transparent, white, transparent);
    border-radius: 2px;
}

.bpo .inventory-table-container {
    display: none;
    overflow-x: auto;
    background: var(--main-background);
}

.bpo .inventory-table-container.active {
    display: block;
}

.bpo .inventory-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 2px;
    min-width: 1000px;
    background: var(--main-background);
    color: var(--main-text-color);
    font-size: 9pt;
}

.bpo .inventory-table th,
.bpo .inventory-table td {
    text-align: left;
    border: 1px solid var(--main-delimiter-light);
    font-size: 9pt;
    padding: 4px 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bpo .inventory-table th {
    background: var(--main-sub-background-filled);
    color: var(--main-text-color);
    font-weight: 600;
    position: sticky;
    left: 259px;
    top: 25px;
    z-index: 10;
    padding: 6px 8px;
}

.bpo .inventory-table tr:hover {
    background: var(--main-hover-interact);
}

.bpo .inventory-table tr:nth-child(even) {
    background: var(--main-sub-background);
}

.bpo .inventory-table tr:nth-child(even):hover {
    background: var(--main-hover-interact);
}

/* Специфичные минимальные ширины для таблиц */
.bpo .detailed-inventory-table {
    background: var(--main-background);
    font-size: 9pt;
    width: 100%;
    color: var(--main-text-color);
}

.bpo .detailed-inventory-table th {
    background: var(--main-sub-background-filled);
    color: var(--main-text-color);
    font-weight: 600;
    padding: 6px 8px;
    text-align: left;
    border: 1px solid var(--main-delimiter-light);
}

.bpo .detailed-inventory-table td {
    padding: 4px 8px;
    border: 1px solid var(--main-delimiter-light);
    vertical-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bpo .detailed-inventory-table tr:hover {
    background: var(--main-hover-interact);
}

.bpo .detailed-inventory-table tr:nth-child(even) {
    background: var(--main-sub-background);
}

.bpo .detailed-inventory-table tr:nth-child(even):hover {
    background: var(--main-hover-interact);
}

.bpo .category-row {
    background: var(--main-sub-background-filled);
    font-weight: 600;
    cursor: pointer;
    border-left: 3px solid var(--main-button-color);
}

.bpo .category-row:hover {
    background: var(--main-hover-interact);
}

.bpo .category-row.hidden {
    display: none;
}

.bpo .category-cell {
    padding: 8px 12px;
    cursor: pointer;
    user-select: none;
}

.bpo .category-cell:hover {
    background: var(--main-hover-interact);
}

.bpo .item-name-cell.category-cell {
    cursor: pointer;
    user-select: none;
    font-weight: 600;
    color: var(--main-text-color);
}

.bpo .item-name-cell.category-cell:hover {
    background: var(--main-hover-interact);
    color: var(--main-button-color);
}

.bpo .expand-icon {
    font-size: 12px;
    margin-right: 8px;
    cursor: pointer;
    user-select: none;
    color: var(--main-button-color);
    font-weight: bold;
}

.bpo .expand-icon:hover {
    color: var(--main-button-hover);
}

.bpo .category-header.expanded .expand-icon {
    transform: rotate(90deg);
}

.bpo .category-name {
    font-weight: 600;
    color: var(--main-text-color);
    font-size: 0.9rem;
}

.bpo .item-row:hover {
    background: var(--main-hover-interact);
}

.bpo .item-row:nth-child(even) {
    background: var(--main-sub-background);
}

.bpo .item-row:nth-child(even):hover {
    background: var(--main-hover-interact);
}

.bpo .item-name-cell {
    padding: 4px 8px;
    max-width: 300px;
}

.bpo .item-name {
    font-weight: 500;
    color: var(--main-text-color);
}

.bpo .actual-input,
.bpo .not-fixed-input,
.bpo .comments-input {
    width: 100%;
    padding: 4px 6px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 3px;
    font-size: 9pt;
    background: var(--main-background);
    color: var(--main-text-color);
}

.bpo .actual-input:focus,
.bpo .not-fixed-input:focus,
.bpo .comments-input:focus {
    outline: none;
    border-color: var(--main-button-color);
    background: var(--main-background);
}

/* Стили для readonly input полей (нет прав на редактирование) */
.bpo .input-readonly,
.bpo .actual-input.input-readonly,
.bpo .not-fixed-input.input-readonly,
.bpo .comments-input.input-readonly {
    background: var(--main-background-secondary) !important;
    cursor: not-allowed;
    opacity: 0.7;
    border-color: var(--main-delimiter-light) !important;
}

.bpo .input-readonly:focus {
    border-color: var(--main-delimiter-light) !important;
}

/* Стили для отображения количества заявки без возможности редактирования */
.bpo .request-count-readonly {
    display: inline-block;
    padding: 4px 8px;
    background: var(--main-background-secondary);
    border-radius: 4px;
    font-weight: 600;
    color: var(--blue);
    font-size: 12px;
}

.bpo .comment-input-ellipsis {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bpo .comment-input-ellipsis:focus {
    text-overflow: clip;
    white-space: normal;
}

.bpo .quantity-cell span,
.bpo .comments-cell span {
    display: inline-block;
    padding: 4px 6px;
    color: var(--main-text-color);
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bpo .photo-cell,
.bpo .request-cell {
    text-align: center;
    padding: 4px;
    vertical-align: middle;
}

.bpo .check-icon:hover {
    color: var(--green);
}

.bpo .request-icon {
    color: var(--orange);
    font-size: 14px;
    cursor: pointer;
}

.bpo .request-icon:hover {
    color: var(--orange);
}

.bpo .request-available {
    color: var(--green);
    font-weight: 600;
}

.bpo .request-needed {
    color: var(--red);
    font-weight: 600;
}

.bpo .serial-number-cell,
.bpo .norm-quantity-cell,
.bpo .ordered-cell,
.bpo .part-number-cell {
    padding: 4px 6px;
    font-size: 9pt;
    color: var(--main-text-color);
}

.bpo .last-changed-cell,
.bpo .engineer-cell {
    padding: 4px 6px;
    font-size: 9pt;
    color: var(--main-text-sub-color);
}

.bpo .engineer-cell {
    font-weight: 500;
}

.bpo .inventory-status {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    color: var(--main-text-color);
}

.bpo .inventory-status-available {
    background-color: rgba(46, 204, 113, 0.15);
    color: var(--green);
    border: 1px solid rgba(46, 204, 113, 0.3);
}

.bpo .inventory-status-moving {
    background-color: rgba(52, 152, 219, 0.15);
    color: var(--color-blue);
    border: 1px solid rgba(52, 152, 219, 0.3);
}

.bpo .inventory-status-maintenance {
    background-color: rgba(243, 156, 18, 0.15);
    color: var(--orange);
    border: 1px solid rgba(243, 156, 18, 0.3);
}

.bpo .inventory-status-working {
    background-color: rgba(155, 89, 182, 0.15);
    color: var(--violet);
    border: 1px solid rgba(155, 89, 182, 0.3);
}

.bpo .status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.bpo .status-in-progress {
    background-color: var(--orange);
    color: white;
}

.bpo .status-completed {
    background-color: var(--green);
    color: white;
}

.bpo .status-cancelled {
    background-color: var(--red);
    color: white;
}

.bpo .status-sent {
    background-color: var(--blue);
    color: white;
}

.bpo .status-processing {
    background-color: var(--orange);
    color: white;
}

.bpo .status-rejected {
    background-color: var(--red);
    color: white;
}

.bpo .status-default {
    background-color: var(--main-text-sub-color);
    color: white;
}

.bpo .applications-header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 20px;
    padding: 20px;
    background: linear-gradient(135deg, var(--main-sub-background-filled) 0%, rgba(52, 152, 219, 0.05) 100%);
    border-radius: 12px;
    border: 1px solid var(--main-delimiter-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.bpo .applications-header-actions button {
    padding: 12px 20px;
    border: 2px solid var(--main-delimiter-light);
    border-radius: 8px;
    background: var(--main-background);
    color: var(--main-text-color);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.85rem;
    font-weight: 600;
    position: relative;
    overflow: hidden;
}

.bpo .applications-header-actions button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.bpo .applications-header-actions button:hover::before {
    left: 100%;
}

.bpo .applications-header-actions button:hover {
    background: linear-gradient(135deg, var(--main-hover-interact) 0%, rgba(52, 152, 219, 0.05) 100%);
    border-color: var(--main-button-color);
    color: var(--main-button-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.2);
}

.bpo .applications-header-actions .btn_primary {
    background: linear-gradient(135deg, var(--main-button-color) 0%, #2980b9 100%);
    color: white;
    border-color: var(--main-button-color);
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.bpo .applications-header-actions .btn_primary:hover {
    background: linear-gradient(135deg, #2980b9 0%, var(--main-button-color) 100%);
    border-color: #2980b9;
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
    transform: translateY(-3px);
}

.bpo .applications-table {
    background: var(--main-background);
    font-size: 9pt;
    width: 100%;
    color: var(--main-text-color);
}

.bpo .applications-table th {
    background: var(--main-sub-background-filled);
    color: var(--main-text-color);
    font-weight: 600;
    padding: 6px 8px;
    text-align: left;
    position: sticky;
    top: 0;
    z-index: 10;
    border: 1px solid var(--main-delimiter-light);
}

.bpo .applications-table td {
    padding: 4px 8px;
    border: 1px solid var(--main-delimiter-light);
    vertical-align: top;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bpo .application-row:hover {
    background: var(--main-hover-interact);
}

.bpo .application-row:nth-child(even) {
    background: var(--main-sub-background);
}

.bpo .application-row:nth-child(even):hover {
    background: var(--main-hover-interact);
}

.bpo .row-number-cell {
    text-align: center;
    font-weight: 600;
    color: var(--main-text-sub-color);
    width: 50px;
}

.bpo .row-number-cell:hover {
    color: var(--main-text-color);
}

.bpo .application-id-cell {
    font-weight: 600;
    color: var(--main-text-color);
}

.bpo .application-id {
    color: var(--main-button-color);
    text-decoration: none;
}

.bpo .category-cell {
    font-weight: 500;
    color: var(--main-text-color);
}

.bpo .name-cell {
    font-weight: 500;
    color: var(--main-text-color);
    max-width: 200px;
}

.bpo .quantity-input,
.bpo .comments-input,
.bpo .shipment-quantity-input,
.bpo .waybill-input,
.bpo .omto-comments-input {
    width: 100%;
    padding: 4px 6px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 3px;
    font-size: 9pt;
    background: var(--main-background);
    color: var(--main-text-color);
}

.bpo .quantity-input:focus,
.bpo .comments-input:focus,
.bpo .shipment-quantity-input:focus,
.bpo .waybill-input:focus,
.bpo .omto-comments-input:focus {
    outline: none;
    border-color: var(--main-button-color);
}

.bpo .application-date-cell,
.bpo .shipment-date-cell {
    font-size: 9pt;
    color: var(--main-text-sub-color);
}

.bpo .status-cell {
    text-align: center;
}

.bpo .create-application-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--main-background);
    border-radius: 8px;
    box-shadow: var(--drop-shadow);
    z-index: 1000;
    min-width: 500px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
}

.bpo .create-application-modal h3 {
    margin: 0 0 20px 0;
    padding: 20px 20px 0 20px;
    color: var(--main-text-color);
    font-size: 1.2rem;
    font-weight: 600;
}

.bpo .form-group {
    margin-bottom: 15px;
    padding: 0 20px;
}

.bpo .form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--main-text-color);
    font-size: 0.9rem;
}

.bpo .form-group input,
.bpo .form-group select,
.bpo .form-group textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 4px;
    font-size: 0.9rem;
    background: var(--main-background);
    color: var(--main-text-color);
    transition: var(--inventory-transition);
}

.bpo .form-group input:focus,
.bpo .form-group select:focus,
.bpo .form-group textarea:focus {
    outline: none;
    border-color: var(--main-button-color);
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.bpo .form-actions {
    padding: 20px;
    border-top: 1px solid var(--main-delimiter-light);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.bpo .form-actions button {
    padding: 8px 16px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 4px;
    background: var(--main-background);
    color: var(--main-text-color);
    cursor: pointer;
    transition: var(--inventory-transition);
    font-size: 0.9rem;
    font-weight: 500;
}

.bpo .form-actions .btn_primary {
    background-color: var(--main-button-color);
    color: var(--main-button-text-color);
    border-color: var(--main-button-color);
}

.bpo .form-actions .btn_primary:hover {
    background-color: var(--main-button-hover);
    border-color: var(--main-button-hover);
}

.bpo .form-actions .secondary {
    background-color: var(--main-background);
    color: var(--main-text-color);
}

.bpo .form-actions .secondary:hover {
    background-color: var(--main-hover-interact);
}

.bpo .history-table {
    background: var(--main-background);
    font-size: 9pt;
    width: 100%;
    color: var(--main-text-color);
}

.bpo .history-table th {
    background: var(--main-sub-background-filled);
    color: var(--main-text-color);
    font-weight: 600;
    padding: 6px 8px;
    text-align: left;
    position: sticky;
    top: 0;
    z-index: 10;
    border: 1px solid var(--main-delimiter-light);
}

.bpo .history-table td {
    padding: 4px 8px;
    border: 1px solid var(--main-delimiter-light);
    vertical-align: top;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bpo .history-row {
    cursor: pointer;
}

.bpo .history-row:hover {
    background: var(--main-hover-interact);
}

.bpo .history-row:nth-child(even) {
    background: var(--main-sub-background);
}

.bpo .history-row:nth-child(even):hover {
    background: var(--main-hover-interact);
}

.bpo .history-table .row-number-cell {
    text-align: center;
    font-weight: 600;
    color: var(--main-text-sub-color);
    width: 50px;
}

.bpo .history-table .name-cell {
    font-weight: 500;
    color: var(--main-text-color);
    max-width: 200px;
}

.bpo .history-table .part-number-cell {
    font-family: monospace;
    font-size: 0.75rem;
    color: var(--main-text-sub-color);
    background-color: var(--main-sub-background-filled);
    padding: 4px 6px;
    border-radius: 3px;
}

.bpo .history-table .change-cell {
    max-width: 300px;
}

.bpo .history-table .last-changed-cell {
    font-size: 0.8rem;
    color: var(--main-text-sub-color);
}

.bpo .history-table .engineer-cell {
    font-weight: 500;
    color: var(--main-text-color);
}

.bpo .change-description {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    margin: 2px;
}

.bpo .change-comment {
    background-color: rgba(52, 152, 219, 0.1);
    color: var(--color-blue);
    border: 1px solid rgba(52, 152, 219, 0.3);
}

.bpo .change-quantity {
    background-color: rgba(46, 204, 113, 0.1);
    color: var(--green);
    border: 1px solid rgba(46, 204, 113, 0.3);
}

.bpo .change-faulty {
    background-color: rgba(231, 76, 60, 0.1);
    color: var(--red);
    border: 1px solid rgba(231, 76, 60, 0.3);
}

.bpo .change-default {
    background-color: var(--main-sub-background-filled);
    color: var(--main-text-color);
    border: 1px solid var(--main-delimiter-light);
}

.bpo .change-details-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--main-background);
    border-radius: 8px;
    box-shadow: var(--drop-shadow);
    z-index: 1000;
    min-width: 500px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
}

.bpo .change-details-modal h3 {
    margin: 0 0 20px 0;
    padding: 20px 20px 0 20px;
    color: var(--main-text-color);
    font-size: 1.2rem;
    font-weight: 600;
}

.bpo .change-details {
    padding: 0 20px 20px 20px;
}

.bpo .detail-row {
    margin-bottom: 15px;
    padding: 10px;
    background: var(--main-sub-background-filled);
    border-radius: 4px;
}

.bpo .detail-row label {
    display: block;
    font-weight: 600;
    color: var(--main-text-color);
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.bpo .detail-row span {
    color: var(--main-text-color);
    font-size: 0.9rem;
}

.bpo .detail-row .change-description {
    display: inline-block;
    margin-top: 5px;
}

.bpo .modal-actions {
    padding: 20px;
    border-top: 1px solid var(--main-delimiter-light);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.bpo .modal-actions button {
    padding: 8px 16px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 4px;
    background: var(--main-background);
    color: var(--main-text-color);
    cursor: pointer;
    transition: var(--inventory-transition);
    font-size: 0.9rem;
    font-weight: 500;
}

.bpo .modal-actions .secondary {
    background-color: var(--main-background);
    color: var(--main-text-color);
}

.bpo .modal-actions .secondary:hover {
    background-color: var(--main-hover-interact);
}

.bpo .item-photo {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--inventory-transition);
}

.bpo .item-photo:hover {
    transform: scale(1.1);
    box-shadow: var(--drop-shadow);
}

.bpo .photo-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    max-width: 95vw;
    max-height: 95vh;
    background: var(--main-background);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--drop-shadow);
    color: var(--main-text-color);
}

.bpo .photo-modal-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.bpo .photo-modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--inventory-transition);
}

.bpo .photo-modal-image:hover {
    transform: scale(1.02);
}

.bpo .inventory-placeholder {
    text-align: center;
    padding: 40px 20px;
    color: var(--main-text-sub-color);
}

.bpo .inventory-placeholder h3 {
    margin-bottom: 15px;
    color: var(--main-text-color);
    font-size: 1.2rem;
}

.bpo .inventory-placeholder p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
}

.bpo .inventory-empty-cell {
    color: var(--main-text-sub-color);
    font-style: italic;
    font-size: 0.85rem;
}

.bpo .version-control {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background: var(--main-sub-background-filled);
    border-radius: var(--inventory-border-radius);
    border: 1px solid var(--main-delimiter-light);
}

.bpo .version-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bpo .version-label {
    font-weight: 500;
    color: var(--main-text-color);
    font-size: 0.9rem;
}

.bpo #version-select {
    padding: 6px 12px;
    border: 1px solid var(--main-delimiter-light);
    border-radius: 4px;
    background: var(--main-background);
    color: var(--main-text-color);
    font-size: 0.9rem;
    cursor: pointer;
}

.bpo .table-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    padding: 20px;
    background: linear-gradient(135deg, var(--main-sub-background-filled) 0%, rgba(52, 152, 219, 0.05) 100%);
    border-radius: 12px;
    border: 1px solid var(--main-delimiter-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.bpo .btn {
    padding: 12px 24px;
    border: 2px solid var(--main-delimiter-light);
    border-radius: 8px;
    background: var(--main-background);
    color: var(--main-text-color);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

.bpo .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.bpo .btn:hover::before {
    left: 100%;
}

.bpo .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.bpo .btn-primary {
    background: linear-gradient(135deg, var(--main-button-color) 0%, #2980b9 100%);
    color: white;
    border-color: var(--main-button-color);
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.bpo .btn-primary:hover {
    background: linear-gradient(135deg, #2980b9 0%, var(--main-button-color) 100%);
    border-color: #2980b9;
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
    transform: translateY(-3px);
}

.bpo .btn-secondary {
    background: var(--main-background);
    color: var(--main-text-color);
    border-color: var(--main-delimiter-light);
}

.bpo .btn-secondary:hover {
    background: linear-gradient(135deg, var(--main-hover-interact) 0%, rgba(52, 152, 219, 0.05) 100%);
    border-color: var(--main-button-color);
    color: var(--main-button-color);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.2);
}

.bpo .expandable-table .category-header {
    background-color: var(--main-sub-background-filled);
    cursor: pointer;
    transition: var(--inventory-transition);
    font-weight: 600;
    padding: 12px;
    border-bottom: 1px solid var(--main-delimiter-light);
}

.bpo .expandable-table .category-header:hover {
    background-color: var(--main-hover-interact);
}

.bpo .photo-placeholder {
    width: 40px;
    height: 40px;
    background-color: var(--main-sub-background-filled);
    border: 2px dashed var(--main-delimiter-light);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--main-text-sub-color);
    font-size: 0.8rem;
    cursor: pointer;
    transition: var(--inventory-transition);
}

.bpo .photo-placeholder:hover {
    border-color: var(--main-button-color);
    color: var(--main-button-color);
    background-color: rgba(52, 152, 219, 0.1);
}

@keyframes historyRowAppear {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bpo .history-row {
    animation: historyRowAppear 0.3s ease-out;
}

@keyframes photoModalAppear {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.bpo .photo-modal {
    animation: photoModalAppear 0.3s ease-out;
}

.bpo .inventory-table-container::-webkit-scrollbar {
    height: 6px;
}

.bpo .inventory-table-container::-webkit-scrollbar-track {
    background: var(--main-sub-background-filled);
}

.bpo .inventory-table-container::-webkit-scrollbar-thumb {
    background: var(--main-delimiter-light);
    border-radius: 3px;
}

.bpo .inventory-table-container::-webkit-scrollbar-thumb:hover {
    background: var(--main-button-color);
}

/* Стили для статусов инвентаря */
.bpo .inventory-status {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.bpo .serial-number-cell,
.bpo .norm-quantity-cell,
.bpo .actual-quantity-cell,
.bpo .not-fixed-cell {
    text-align: center;
}

.bpo .inventory-status-available {
    background-color: rgba(34, 197, 94, 0.1);
    color: #16a34a;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.bpo .inventory-status-in-knbk {
    background-color: rgba(59, 130, 246, 0.1);
    color: #2563eb;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.bpo .inventory-status-moving {
    background-color: rgba(245, 158, 11, 0.1);
    color: #d97706;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.bpo .inventory-status-returned {
    background-color: rgba(107, 114, 128, 0.1);
    color: #6b7280;
    border: 1px solid rgba(107, 114, 128, 0.2);
}

.bpo .inventory-status-unknown {
    background-color: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.bpo .delete-icon {
    display: inline-block;
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    margin-right: 8px;
    vertical-align: middle;
}

.bpo .delete-icon:hover {
    background-color: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    transform: scale(1.1);
}

.bpo .delete-icon:active {
    transform: scale(0.95);
    background-color: rgba(239, 68, 68, 0.2);
}

.bpo .request-cell-container {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    width: 100%;
}

.bpo .request-progress-bar {
    display: flex;
    width: 100%;
    max-width: 120px;
    height: 28px;
    border-radius: 14px;
    overflow: hidden;
    background-color: var(--input-bg);
    border: 1px solid var(--border-color);
}

.bpo .progress-segment {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: width 0.3s ease;
}

.bpo .progress-segment.progress-green {
    background-color: #10b981;
    color: white;
}

.bpo .progress-segment.progress-white {
    background-color: #ffffff;
    color: #374151;
    border-left: 1px solid #e5e7eb;
}

.bpo .progress-label {
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    padding: 0 6px;
}

.bpo .request-icons-container {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.bpo .request-in-transit {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background-color: #f3f4f6;
    border-radius: 12px;
    border: 1px solid #d1d5db;
}

.bpo .truck-icon {
    font-size: 16px;
    line-height: 1;
}

.bpo .transit-badge {
    font-size: 11px;
    font-weight: 600;
    color: #3b82f6;
    line-height: 1;
}

.bpo .request-edit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 28px;
    padding: 0 10px;
    background-color: #3b82f6;
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.2);
}

.bpo .request-edit-btn:hover {
    background-color: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(59, 130, 246, 0.3);
}

.bpo .request-edit-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(59, 130, 246, 0.2);
}

.bpo .request-icon.request-available {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: transform 0.2s ease;
}

.bpo .request-icon.request-available:hover {
    transform: scale(1.1);
}

.bpo .request-icon.request-available:active {
    transform: scale(0.95);
}

html.dark .request-progress-bar {
    background-color: var(--input-bg);
    border-color: var(--border-color);
}

html.dark .progress-segment.progress-white {
    background-color: #4b5563;
    color: #d1d5db;
    border-left-color: #6b7280;
}

html.dark .request-in-transit {
    background-color: #374151;
    border-color: #4b5563;
}

html.dark .transit-badge {
    color: #60a5fa;
}