/* Custom styles for Physical Storage Management System */

:root {
    --primary-color: #0d6efd;
    --success-color: #198754;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
}

body {
    background-color: #f8f9fa;
}

/* Scanner input styling */
.scan-input {
    font-size: 1.5rem;
    padding: 1rem;
    text-align: center;
    font-family: monospace;
    letter-spacing: 0.1em;
}

.scan-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.scan-input.scanning {
    background-color: #e8f4ff;
}

/* Current bin indicator */
.bin-indicator {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
}

.bin-indicator.no-bin {
    background-color: #fff3cd;
    border: 1px solid var(--warning-color);
}

.bin-indicator.has-bin {
    background-color: #d1e7dd;
    border: 1px solid var(--success-color);
}

/* Activity log */
.activity-log {
    max-height: 300px;
    overflow-y: auto;
}

.activity-item {
    padding: 0.5rem;
    border-bottom: 1px solid #dee2e6;
    animation: fadeIn 0.3s ease-in;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-item.created {
    background-color: #d1e7dd;
}

.activity-item.moved {
    background-color: #fff3cd;
}

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

/* Toast notifications */
.toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1050;
}

/* Inventory table */
.inventory-table th {
    position: sticky;
    top: 0;
    background-color: white;
    z-index: 1;
}

.bin-row {
    cursor: pointer;
}

.bin-row:hover {
    background-color: #f8f9fa;
}

.items-row {
    background-color: #f8f9fa;
}

.item-card {
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
}

.item-card:hover {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Item picture */
.item-picture {
    max-width: 100px;
    max-height: 100px;
    object-fit: cover;
    border-radius: 0.25rem;
}

.item-picture-large {
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
}

/* Metadata editor */
.metadata-row {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.metadata-row input {
    flex: 1;
}

/* Search box */
.search-box {
    max-width: 400px;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #6c757d;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Loading spinner */
.loading-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .scan-input {
        font-size: 1.25rem;
    }

    .container-fluid {
        padding: 0.5rem;
    }
}
