/* css/inventario.css - Inventory Management Styling */

/* ===== INVENTORY SECTION ===== */
.inventario-lista {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.inventario-header {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    margin-bottom: var(--space-lg);
}

.inventario-header h4 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: var(--space);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.inventario-header h4::before {
    content: '📦';
    font-size: 1.5rem;
}

.inventario-header p {
    color: var(--text-light);
    margin-bottom: var(--space);
}

/* ===== INVENTORY ALERTS ===== */
.inventario-header > div {
    padding: var(--space);
    border-radius: var(--radius);
    margin: var(--space) 0;
}

.inventario-header > div:has(p:contains("✅")) {
    background: var(--success-light);
    border: 1px solid var(--success);
    color: var(--success);
}

.inventario-header > div:has(p:contains("⚠️")) {
    background: var(--warning-light);
    border: 1px solid var(--warning);
    color: var(--warning);
}

/* ===== INVENTORY ITEMS GRID ===== */
.inventario-item {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.inventario-item:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
    transform: translateY(-1px);
}

.item-info {
    flex: 1;
}

.item-info h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    color: var(--text);
}

.item-info p {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: var(--space-xs);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.item-info p strong {
    color: var(--text);
    font-weight: 600;
    min-width: 120px;
}

.item-info p:has(strong:contains("Stock")) {
    color: var(--text);
    font-weight: 600;
}

.item-info p:has(strong:contains("STOCK BAJO")) {
    color: var(--danger);
    font-weight: 700;
    background: var(--danger-light);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius);
}

.item-actions {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    margin-left: var(--space-lg);
}

.item-actions button {
    background: var(--primary);
    color: white;
    border: none;
    padding: var(--space-sm) var(--space);
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.item-actions button:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* ===== PRICE EDITOR ===== */
.editor-precios {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    margin-bottom: var(--space-lg);
}

.editor-precios h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: var(--space);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.editor-precios h3::before {
    content: '📝';
    font-size: 1.5rem;
}

.precios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space);
    margin: var(--space-lg) 0;
}

.precio-item {
    background: var(--gray-50);
    padding: var(--space);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
}

.precio-item label {
    display: block;
    font-weight: 600;
    color: var(--text);
    margin-bottom: var(--space-sm);
}

.precio-item input {
    width: 100%;
    padding: var(--space-sm) var(--space);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.precio-item input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.precio-item small {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin-top: var(--space-xs);
    display: block;
}

.form-actions {
    display: flex;
    gap: var(--space);
    justify-content: center;
    margin-top: var(--space-lg);
}

/* ===== FORM STYLING ===== */
.formulario-ingrediente {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    margin-bottom: var(--space-lg);
}

.formulario-ingrediente h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.formulario-ingrediente h3::before {
    content: '➕';
    font-size: 1.5rem;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .inventario-item {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space);
    }
    
    .item-actions {
        width: 100%;
        flex-direction: row;
        justify-content: center;
        margin-left: 0;
    }
    
    .item-actions button {
        flex: 1;
    }
    
    .precios-grid {
        grid-template-columns: 1fr;
    }
}